Core::ModeManager Class
class Core::ModeManagerModeManager クラスは、モードの有効化およびモードセレクタのツールバー上のアクションを管理します。詳細...
| Header: | #include <coreplugin/modemanager.h> |
| Inherits: | QObject |
シグナル
| void | currentModeChanged(Utils::Id mode, Utils::Id oldMode = {}) |
静的パブリックメンバー
| void | activateMode(Utils::Id id) |
| void | addAction(QAction *action, int priority) |
| Core::IMode * | currentMode() |
| Utils::Id | currentModeId() |
| Core::ModeManager * | instance() |
詳細な説明
モードは、IMode クラスによって実装されています。ModeManagerを使用すると、モードの有効化を強制したり、アクティブなモードが変更された際に通知を受け取ったりすることができます。
ModeManager は、モードセレクタのツールバーに表示されるアクションも管理します。ツールバーへのアクションの追加は、極力控えるようにしてください。
メンバ関数のドキュメント
[static] void ModeManager::activateMode(Utils::Id id)
IDがid のモードを現在のモードに設定します。
currentMode()、currentModeId()、currentModeAboutToChange()、およびcurrentModeChanged()も参照してください 。
[static] void ModeManager::addAction(QAction *action, int priority)
モードセレクタのツールバーに「action 」を追加します。アクションは「priority 」の値の降順で並べ替えられます。この機能の使用は極力控えてください。
[static] Core::IMode *ModeManager::currentMode()
現在のモードへのポインタを返します。
activateMode() およびcurrentModeId()も参照してください 。
[signal] void ModeManager::currentModeChanged(Utils::Id mode, Utils::Id oldMode = {})
電流モードが「oldMode 」から「mode 」に変更された後に発行されました。
[static] Utils::Id ModeManager::currentModeId()
現在のモードのIDを返します。
activateMode() およびcurrentMode()も参照してください 。
[static] Core::ModeManager *ModeManager::instance()
インスタンスへのポインタを返します。シグナルへの接続にのみ使用してください。
Copyright © The Qt Company Ltd. and other contributors. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.