Fawkes API
Fawkes Development Version
|
00001 00002 /*************************************************************************** 00003 * netloggui.h - NetLog GUI 00004 * 00005 * Created: Tue Nov 03 23:38:11 2008 00006 * Copyright 2008 Tim Niemueller [www.niemueller.de] 00007 * 00008 ****************************************************************************/ 00009 00010 /* This program is free software; you can redistribute it and/or modify 00011 * it under the terms of the GNU General Public License as published by 00012 * the Free Software Foundation; either version 2 of the License, or 00013 * (at your option) any later version. 00014 * 00015 * This program is distributed in the hope that it will be useful, 00016 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00017 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00018 * GNU Library General Public License for more details. 00019 * 00020 * Read the full text in the LICENSE.GPL file in the doc directory. 00021 */ 00022 00023 #ifndef __TOOLS_NETLOGGUI_NETLOGGUI_H_ 00024 #define __TOOLS_NETLOGGUI_NETLOGGUI_H_ 00025 00026 #include <gtkmm.h> 00027 00028 namespace fawkes { 00029 class AvahiThread; 00030 class LogView; 00031 class NetworkService; 00032 class AvahiDispatcher; 00033 } 00034 00035 class NetLogGuiGtkWindow : public Gtk::Window 00036 { 00037 public: 00038 NetLogGuiGtkWindow(BaseObjectType* cobject, 00039 const Glib::RefPtr<Gtk::Builder> &builder); 00040 ~NetLogGuiGtkWindow(); 00041 00042 private: 00043 int on_service_added(fawkes::NetworkService *service); 00044 void on_service_removed(fawkes::NetworkService *service); 00045 00046 void on_connection_clicked(); 00047 void on_exit_clicked(); 00048 void on_clear_clicked(); 00049 00050 void on_connbut_clicked(Gtk::Image *image, fawkes::LogView *logview); 00051 void on_connected(Gtk::Image *image); 00052 void on_disconnected(Gtk::Image *image); 00053 00054 private: 00055 fawkes::AvahiThread *avahi_thread; 00056 fawkes::AvahiDispatcher *avahi_dispatcher; 00057 00058 Gtk::VBox *vbox_main; 00059 Gtk::Label *lab_no_connection; 00060 Gtk::ToolButton *tb_connection; 00061 Gtk::ToolButton *tb_exit; 00062 Gtk::ToolButton *tb_clear; 00063 00064 Gtk::Notebook ntb_logviewers; 00065 }; 00066 00067 #endif