Bunch of renames to reduce confusion.
This commit is contained in:
parent
cbb2f897aa
commit
be2ffd7ef9
15 changed files with 184 additions and 184 deletions
|
|
@ -1,47 +0,0 @@
|
|||
#ifndef LWIDGETACTION_H
|
||||
#define LWIDGETACTION_H
|
||||
|
||||
#include "MenuLocation.h"
|
||||
#include "ToolbarLocation.h"
|
||||
#include <QIcon>
|
||||
#include <QKeySequence>
|
||||
#include <QString>
|
||||
|
||||
|
||||
/** Action definition for a specific widget instance, it uses a slotname
|
||||
* so the action can be defined before the widget instance is created.
|
||||
* The plugin mechanism will take care of instantiating a connection to the named slot.
|
||||
*/
|
||||
class LWidgetAction {
|
||||
public:
|
||||
///
|
||||
/// \param slotname, use SLOT macro to pass name of the slot
|
||||
LWidgetAction(QString text, const char * slotname);
|
||||
|
||||
const QIcon& icon() const;
|
||||
const MenuLocation& menuLocation() const;
|
||||
void setIcon(QIcon icon);
|
||||
void setIcon(const char * icon) { setIcon(QIcon(icon)); }
|
||||
void setMenuLocation(MenuLocation menu_location);
|
||||
void setMenuLocation(const char * menu_location) { setMenuLocation(MenuPath(menu_location)); }
|
||||
void setToolbarLocation(ToolbarLocation toolbar_location);
|
||||
void setShortcut(QKeySequence shortcut);
|
||||
void setText(QString text);
|
||||
void setToolTip(QString tooltip);
|
||||
const QKeySequence& shortcut() const;
|
||||
const char* slotName() const { return m_slotname; }
|
||||
const QString& text() const;
|
||||
const QString& toolTip() const;
|
||||
|
||||
private:
|
||||
QString m_text;
|
||||
QString m_toolTip;
|
||||
QIcon m_icon;
|
||||
QKeySequence m_shortCut;
|
||||
MenuLocation m_menuLocation;
|
||||
ToolbarLocation m_toolbarLocation;
|
||||
|
||||
const char * m_slotname;
|
||||
};
|
||||
|
||||
#endif // LWIDGETACTION_H
|
||||
Loading…
Add table
Add a link
Reference in a new issue