Fixed terminal output when running GUI

This commit is contained in:
zvon 2020-01-19 12:03:38 +01:00
parent 3f6c97bda7
commit 10aec4e41b
5 changed files with 4 additions and 5 deletions

View File

@ -582,7 +582,9 @@ void refreshDB( bool linux, void *progress_ptr ) {
for ( auto &show : shows ) { for ( auto &show : shows ) {
if ( FSLib::exists( show[TEXT( "PATH" )] ) ) { if ( FSLib::exists( show[TEXT( "PATH" )] ) ) {
#ifndef GUI
cleanUpLine(); cleanUpLine();
#endif
p.print( TEXT( "Refreshing " ) + show[TEXT( "SHOW" )] ); p.print( TEXT( "Refreshing " ) + show[TEXT( "SHOW" )] );
p.print( 0 ); p.print( 0 );
std::map< int, std::map< int, string > > seasons; std::map< int, std::map< int, string > > seasons;
@ -669,7 +671,9 @@ void updateDB( bool linux, void *progress_ptr ) {
if ( !FSLib::exists( show[TEXT( "PATH" )] ) ) { if ( !FSLib::exists( show[TEXT( "PATH" )] ) ) {
continue; continue;
} }
#ifndef GUI
cleanUpLine(); cleanUpLine();
#endif
p.print( TEXT( "Updating " ) + show[TEXT( "SHOW" )] ); p.print( TEXT( "Updating " ) + show[TEXT( "SHOW" )] );
std::unordered_set< string > episodes; std::unordered_set< string > episodes;

View File

@ -5,7 +5,6 @@
#include <gtkmm/messagedialog.h> #include <gtkmm/messagedialog.h>
#include <gtkmm/scrolledwindow.h> #include <gtkmm/scrolledwindow.h>
#include <gtkmm/textview.h> #include <gtkmm/textview.h>
#include <iostream>
#include <thread> #include <thread>
#include "databasewindow.hpp" #include "databasewindow.hpp"

View File

@ -12,7 +12,6 @@
#include <gtkmm/menubar.h> #include <gtkmm/menubar.h>
#include <gtkmm/menuitem.h> #include <gtkmm/menuitem.h>
#include <gtkmm/window.h> #include <gtkmm/window.h>
#include <iostream>
#include <set> #include <set>
#include "network.hpp" #include "network.hpp"

View File

@ -1,5 +1,4 @@
#include <gtkmm/liststore.h> #include <gtkmm/liststore.h>
#include <iostream>
#include <mutex> #include <mutex>
#include "functions.hpp" #include "functions.hpp"
@ -10,7 +9,6 @@ ProgressWindow::ProgressWindow() {
set_default_size( 500, 55 ); set_default_size( 500, 55 );
std::cout << "Layout" << std::endl;
add( *layout ); add( *layout );
set_size_request( 500, 55 ); set_size_request( 500, 55 );
set_resizable( false ); set_resizable( false );

View File

@ -5,7 +5,6 @@
#include <gtkmm/layout.h> #include <gtkmm/layout.h>
#include <gtkmm/progressbar.h> #include <gtkmm/progressbar.h>
#include <gtkmm/window.h> #include <gtkmm/window.h>
#include <iostream>
class ProgressWindow : public Gtk::Window { class ProgressWindow : public Gtk::Window {
public: public: