X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;ds=sidebyside;f=src%2Fuisupport%2Fgraphicalui.h;h=42a0a01cd70def56931862b6c192029ac4d5c5e5;hb=bb51c809ad956b869181fd2475a62fd5404ba326;hp=88d94fe9a29657a1c0df8a1a3b6869d2a269e98f;hpb=74a5ad0fb62894e054dabbad11c9ad9dad4941ec;p=quassel.git diff --git a/src/uisupport/graphicalui.h b/src/uisupport/graphicalui.h index 88d94fe9..42a0a01c 100644 --- a/src/uisupport/graphicalui.h +++ b/src/uisupport/graphicalui.h @@ -1,5 +1,5 @@ /*************************************************************************** - * Copyright (C) 2005-09 by the Quassel Project * + * Copyright (C) 2005-2010 by the Quassel Project * * devel@quassel-irc.org * * * * This program is free software; you can redistribute it and/or modify * @@ -46,6 +46,15 @@ public: * @param category The category (default: "General") */ static ActionCollection *actionCollection(const QString &category = "General"); + static QHash actionCollections(); + + //! Load custom shortcuts from ShortcutSettings + /** @note This method assumes that all configurable actions are defined when being called + */ + static void loadShortcuts(); + + //! Save custom shortcuts to ShortcutSettings + static void saveShortcuts(); inline static ContextMenuActionProvider *contextMenuActionProvider(); inline static ToolBarActionProvider *toolBarActionProvider(); @@ -61,6 +70,9 @@ public: //! Toggle main widget static void toggleMainWidget(); + //! Check if the main widget if (fully, in KDE) visible + static bool isMainWidgetVisible(); + protected: //! This is the widget we associate global actions with, typically the main window void setMainWidget(QWidget *); @@ -70,7 +82,7 @@ protected: * it should be activated or hidden. Without KDE, we need to resort to checking the current state * as Qt knows it, ignoring windows covering it. * @param performToggle If true, toggle the window's state in addition to checking visibility - * @return True, if the window is currently visible + * @return True, if the window is currently *not* visible (needs activation) */ bool checkMainWidgetVisibility(bool performToggle); @@ -89,6 +101,9 @@ protected: virtual bool eventFilter(QObject *obj, QEvent *event); +protected slots: + virtual void disconnectedFromCore(); + private: static inline GraphicalUi *instance();