1 /***************************************************************************
2 * Copyright (C) 2004 by Kita Developers *
3 * ikemo@users.sourceforge.jp *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 2 of the License, or *
8 * (at your option) any later version. *
9 ***************************************************************************/
18 #include <kapplication.h>
19 #include <kparts/dockmainwindow.h>
27 class KitaBBSTabWidget;
28 class KitaBoardTabWidget;
31 class KitaThreadTabWidget;
33 class KitaWriteTabWidget;
42 * This class serves as the main window for Kita. It handles the
43 * menus, toolbars, and status bars.
45 * @short Main window class
46 * @author $AUTHOR <$EMAIL>
47 * @version $APP_VERSION
50 class KitaMainWindow : public KDockMainWindow
55 virtual ~KitaMainWindow();
57 void load( const KURL& url );
58 void slotSetMainStatusbar( const QString& statusStr );
59 void setUrl( const KURL& url );
60 void bookmark( const QString& datURL, bool on );
63 void closeSubjectView();
65 void newToolbarConfig();
66 void optionsShowToolbar();
67 void optionsShowStatusbar();
68 void optionsConfigureKeys();
69 void optionsConfigureToolbars();
70 void optionsPreferences();
71 void settingsMenuAboutToShow();
72 void setFont( const QFont& font );
73 void windowToggleView();
75 void slotCheckBoardToggleAction( bool check );
76 void slotCheckSubjectToggleAction( bool check );
77 void slotCheckWriteToggleAction( bool check );
79 void slotOpenURLRequest( const KURL& url, const KParts::URLArgs& );
80 void slotOpenURLRequestExt( const KURL& url, const QString mimetype = QString::null );
86 KToggleAction *m_toolbarAction;
87 KToggleAction *m_statusbarAction;
88 KToggleAction *m_boardListAction;
89 KToggleAction* m_subjectListAction;
90 KToggleAction* m_showWriteDockAction;
91 KAction* m_toggleViewAction;
93 KDockWidget* m_dummyDock; /* dummy MainDockWidget */
94 KitaBBSDock* m_bbsDock;
95 KitaBoardDock* m_boardDock;
96 KitaThreadDock* m_threadDock;
97 KitaWriteDock* m_writeDock;
99 KitaThreadTabWidget* m_threadTab;
100 KitaBBSTabWidget* m_bbsTab;
101 KitaBoardTabWidget* m_boardTab;
102 KitaWriteTabWidget* m_writeTab;
108 void loadFavorites();
109 void saveFavorites();
110 void loadFavoriteBoards();
111 void saveFavoriteBoards();
112 void loadCompletion();
113 void loadStyleSheet();
114 void saveStyleSheet();
116 void loadAboneIDList();
117 void loadAboneNameList();
118 void loadAboneWordList();
121 void favoritesUpdated();