api to access to containment actions
This commit is contained in:
parent
bada0c97ba
commit
6bccf2d1af
@ -70,6 +70,14 @@ void PanelConfigView::init()
|
|||||||
syncGeometry();
|
syncGeometry();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QAction *PanelConfigView::action(const QString &name)
|
||||||
|
{
|
||||||
|
if (m_containment) {
|
||||||
|
return m_containment->actions()->action(name);
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
void PanelConfigView::showAddWidgetDialog()
|
void PanelConfigView::showAddWidgetDialog()
|
||||||
{
|
{
|
||||||
QAction *addWidgetAction = m_containment->actions()->action("add widgets");
|
QAction *addWidgetAction = m_containment->actions()->action("add widgets");
|
||||||
@ -107,7 +115,7 @@ void PanelConfigView::syncGeometry()
|
|||||||
void PanelConfigView::focusOutEvent(QFocusEvent *ev)
|
void PanelConfigView::focusOutEvent(QFocusEvent *ev)
|
||||||
{
|
{
|
||||||
Q_UNUSED(ev)
|
Q_UNUSED(ev)
|
||||||
//close();
|
close();
|
||||||
}
|
}
|
||||||
|
|
||||||
#include "moc_panelconfigview.cpp"
|
#include "moc_panelconfigview.cpp"
|
||||||
|
@ -47,6 +47,8 @@ public:
|
|||||||
|
|
||||||
void init();
|
void init();
|
||||||
|
|
||||||
|
Q_INVOKABLE QAction *action(const QString &name);
|
||||||
|
|
||||||
public Q_SLOTS:
|
public Q_SLOTS:
|
||||||
void showAddWidgetDialog();
|
void showAddWidgetDialog();
|
||||||
|
|
||||||
|
@ -265,7 +265,7 @@ void PanelView::setVisibilityMode(PanelView::VisibilityMode mode)
|
|||||||
show();
|
show();
|
||||||
|
|
||||||
disconnect(containment(), SIGNAL(activate()), this, SLOT(unhide()));
|
disconnect(containment(), SIGNAL(activate()), this, SLOT(unhide()));
|
||||||
if (!(mode == NormalPanel && mode == WindowsGoBelow)) {
|
if (!(mode == NormalPanel || mode == WindowsGoBelow)) {
|
||||||
connect(containment(), SIGNAL(activate()), this, SLOT(unhide()));
|
connect(containment(), SIGNAL(activate()), this, SLOT(unhide()));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user