Adding upstream version 0.9.0+20151027.
This commit is contained in:
parent
c646cdaab7
commit
161a7316cf
@ -63,8 +63,7 @@ LXQtMainMenu::LXQtMainMenu(const ILXQtPanelPluginStartupInfo &startupInfo):
|
|||||||
QObject(),
|
QObject(),
|
||||||
ILXQtPanelPlugin(startupInfo),
|
ILXQtPanelPlugin(startupInfo),
|
||||||
mMenu(0),
|
mMenu(0),
|
||||||
mShortcut(0),
|
mShortcut(0)
|
||||||
mLockCascadeChanges(false)
|
|
||||||
{
|
{
|
||||||
#ifdef HAVE_MENU_CACHE
|
#ifdef HAVE_MENU_CACHE
|
||||||
mMenuCache = NULL;
|
mMenuCache = NULL;
|
||||||
@ -84,8 +83,18 @@ LXQtMainMenu::LXQtMainMenu(const ILXQtPanelPluginStartupInfo &startupInfo):
|
|||||||
|
|
||||||
settingsChanged();
|
settingsChanged();
|
||||||
|
|
||||||
|
mShortcut = GlobalKeyShortcut::Client::instance()->addAction(QString{}, QString("/panel/%1/show_hide").arg(settings()->group()), tr("Show/hide main menu"), this);
|
||||||
|
if (mShortcut)
|
||||||
|
{
|
||||||
|
connect(mShortcut, &GlobalKeyShortcut::Action::registrationFinished, [this] {
|
||||||
|
if (mShortcut->shortcut().isEmpty())
|
||||||
|
mShortcut->changeShortcut(DEFAULT_SHORTCUT);
|
||||||
|
else
|
||||||
|
mShortcutSeq = QKeySequence(mShortcut->shortcut());
|
||||||
|
});
|
||||||
connect(mShortcut, SIGNAL(activated()), &mDelayedPopup, SLOT(start()));
|
connect(mShortcut, SIGNAL(activated()), &mDelayedPopup, SLOT(start()));
|
||||||
connect(mShortcut, SIGNAL(shortcutChanged(QString,QString)), this, SLOT(shortcutChanged(QString,QString)));
|
connect(mShortcut, SIGNAL(shortcutChanged(QString,QString)), this, SLOT(shortcutChanged(QString,QString)));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -124,13 +133,8 @@ void LXQtMainMenu::shortcutChanged(const QString &/*oldShortcut*/, const QString
|
|||||||
{
|
{
|
||||||
if (!newShortcut.isEmpty())
|
if (!newShortcut.isEmpty())
|
||||||
{
|
{
|
||||||
mLockCascadeChanges = true;
|
|
||||||
|
|
||||||
settings()->setValue("dialog/shortcut", newShortcut);
|
|
||||||
settings()->sync();
|
|
||||||
mShortcutSeq = QKeySequence(newShortcut);
|
mShortcutSeq = QKeySequence(newShortcut);
|
||||||
|
|
||||||
mLockCascadeChanges = false;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -161,9 +165,6 @@ void LXQtMainMenu::menuCacheReloadNotify(MenuCache* cache, gpointer user_data)
|
|||||||
************************************************/
|
************************************************/
|
||||||
void LXQtMainMenu::settingsChanged()
|
void LXQtMainMenu::settingsChanged()
|
||||||
{
|
{
|
||||||
if (mLockCascadeChanges)
|
|
||||||
return;
|
|
||||||
|
|
||||||
if (settings()->value("showText", false).toBool())
|
if (settings()->value("showText", false).toBool())
|
||||||
{
|
{
|
||||||
mButton.setText(settings()->value("text", "Start").toString());
|
mButton.setText(settings()->value("text", "Start").toString());
|
||||||
@ -213,18 +214,6 @@ void LXQtMainMenu::settingsChanged()
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
QString shortcut = settings()->value("shortcut", DEFAULT_SHORTCUT).toString();
|
|
||||||
if (shortcut.isEmpty())
|
|
||||||
shortcut = DEFAULT_SHORTCUT;
|
|
||||||
|
|
||||||
if (!mShortcut)
|
|
||||||
mShortcut = GlobalKeyShortcut::Client::instance()->addAction(shortcut, QString("/panel/%1/show_hide").arg(settings()->group()), tr("Show/hide main menu"), this);
|
|
||||||
else if (mShortcut->shortcut() != shortcut)
|
|
||||||
{
|
|
||||||
mShortcut->changeShortcut(shortcut);
|
|
||||||
}
|
|
||||||
mShortcutSeq = QKeySequence(shortcut);
|
|
||||||
|
|
||||||
setMenuFontSize();
|
setMenuFontSize();
|
||||||
|
|
||||||
realign();
|
realign();
|
||||||
@ -301,7 +290,7 @@ void LXQtMainMenu::setMenuFontSize()
|
|||||||
************************************************/
|
************************************************/
|
||||||
QDialog *LXQtMainMenu::configureDialog()
|
QDialog *LXQtMainMenu::configureDialog()
|
||||||
{
|
{
|
||||||
return new LXQtMainMenuConfiguration(*settings(), DEFAULT_SHORTCUT);
|
return new LXQtMainMenuConfiguration(*settings(), mShortcut, DEFAULT_SHORTCUT);
|
||||||
}
|
}
|
||||||
/************************************************
|
/************************************************
|
||||||
|
|
||||||
|
@ -95,7 +95,6 @@ private:
|
|||||||
XdgMenu mXdgMenu;
|
XdgMenu mXdgMenu;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
bool mLockCascadeChanges;
|
|
||||||
QTimer mDelayedPopup;
|
QTimer mDelayedPopup;
|
||||||
QTimer mHideTimer;
|
QTimer mHideTimer;
|
||||||
QKeySequence mShortcutSeq;
|
QKeySequence mShortcutSeq;
|
||||||
|
@ -30,15 +30,17 @@
|
|||||||
#include "ui_lxqtmainmenuconfiguration.h"
|
#include "ui_lxqtmainmenuconfiguration.h"
|
||||||
#include <XdgMenu>
|
#include <XdgMenu>
|
||||||
#include <XdgIcon>
|
#include <XdgIcon>
|
||||||
|
#include <lxqt-globalkeys.h>
|
||||||
|
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
|
|
||||||
LXQtMainMenuConfiguration::LXQtMainMenuConfiguration(QSettings &settings, const QString &defaultShortcut, QWidget *parent) :
|
LXQtMainMenuConfiguration::LXQtMainMenuConfiguration(QSettings &settings, GlobalKeyShortcut::Action * shortcut, const QString &defaultShortcut, QWidget *parent) :
|
||||||
QDialog(parent),
|
QDialog(parent),
|
||||||
ui(new Ui::LXQtMainMenuConfiguration),
|
ui(new Ui::LXQtMainMenuConfiguration),
|
||||||
mSettings(settings),
|
mSettings(settings),
|
||||||
mOldSettings(settings),
|
mOldSettings(settings),
|
||||||
mDefaultShortcut(defaultShortcut)
|
mDefaultShortcut(defaultShortcut),
|
||||||
|
mShortcut(shortcut)
|
||||||
{
|
{
|
||||||
setAttribute(Qt::WA_DeleteOnClose);
|
setAttribute(Qt::WA_DeleteOnClose);
|
||||||
setObjectName("MainMenuConfigurationWindow");
|
setObjectName("MainMenuConfigurationWindow");
|
||||||
@ -63,6 +65,8 @@ LXQtMainMenuConfiguration::LXQtMainMenuConfiguration(QSettings &settings, const
|
|||||||
|
|
||||||
connect(ui->customFontCB, SIGNAL(toggled(bool)), this, SLOT(customFontChanged(bool)));
|
connect(ui->customFontCB, SIGNAL(toggled(bool)), this, SLOT(customFontChanged(bool)));
|
||||||
connect(ui->customFontSizeSB, SIGNAL(valueChanged(int)), this, SLOT(customFontSizeChanged(int)));
|
connect(ui->customFontSizeSB, SIGNAL(valueChanged(int)), this, SLOT(customFontSizeChanged(int)));
|
||||||
|
|
||||||
|
connect(mShortcut, &GlobalKeyShortcut::Action::shortcutChanged, this, &LXQtMainMenuConfiguration::globalShortcutChanged);
|
||||||
}
|
}
|
||||||
|
|
||||||
LXQtMainMenuConfiguration::~LXQtMainMenuConfiguration()
|
LXQtMainMenuConfiguration::~LXQtMainMenuConfiguration()
|
||||||
@ -81,7 +85,7 @@ void LXQtMainMenuConfiguration::loadSettings()
|
|||||||
menuFile = XdgMenu::getMenuFileName();
|
menuFile = XdgMenu::getMenuFileName();
|
||||||
}
|
}
|
||||||
ui->menuFilePathLE->setText(menuFile);
|
ui->menuFilePathLE->setText(menuFile);
|
||||||
ui->shortcutEd->setText(mSettings.value("shortcut", "Alt+F1").toString());
|
ui->shortcutEd->setText(nullptr != mShortcut ? mShortcut->shortcut() : mDefaultShortcut);
|
||||||
|
|
||||||
ui->customFontCB->setChecked(mSettings.value("customFont", false).toBool());
|
ui->customFontCB->setChecked(mSettings.value("customFont", false).toBool());
|
||||||
LXQt::Settings lxqtSettings("lxqt"); //load system font size as init value
|
LXQt::Settings lxqtSettings("lxqt"); //load system font size as init value
|
||||||
@ -116,10 +120,15 @@ void LXQtMainMenuConfiguration::chooseMenuFile()
|
|||||||
d->show();
|
d->show();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void LXQtMainMenuConfiguration::globalShortcutChanged(const QString &/*oldShortcut*/, const QString &newShortcut)
|
||||||
|
{
|
||||||
|
ui->shortcutEd->setText(newShortcut);
|
||||||
|
}
|
||||||
|
|
||||||
void LXQtMainMenuConfiguration::shortcutChanged(const QString &value)
|
void LXQtMainMenuConfiguration::shortcutChanged(const QString &value)
|
||||||
{
|
{
|
||||||
ui->shortcutEd->setText(value);
|
if (mShortcut)
|
||||||
mSettings.setValue("shortcut", value);
|
mShortcut->changeShortcut(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
void LXQtMainMenuConfiguration::shortcutReset()
|
void LXQtMainMenuConfiguration::shortcutReset()
|
||||||
|
@ -40,12 +40,16 @@ namespace Ui {
|
|||||||
class LXQtMainMenuConfiguration;
|
class LXQtMainMenuConfiguration;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace GlobalKeyShortcut {
|
||||||
|
class Action;
|
||||||
|
}
|
||||||
|
|
||||||
class LXQtMainMenuConfiguration : public QDialog
|
class LXQtMainMenuConfiguration : public QDialog
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit LXQtMainMenuConfiguration(QSettings &settings, const QString &defaultShortcut, QWidget *parent = 0);
|
explicit LXQtMainMenuConfiguration(QSettings &settings, GlobalKeyShortcut::Action * shortcut, const QString &defaultShortcut, QWidget *parent = 0);
|
||||||
~LXQtMainMenuConfiguration();
|
~LXQtMainMenuConfiguration();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
@ -53,8 +57,11 @@ private:
|
|||||||
QSettings &mSettings;
|
QSettings &mSettings;
|
||||||
LXQt::SettingsCache mOldSettings;
|
LXQt::SettingsCache mOldSettings;
|
||||||
QString mDefaultShortcut;
|
QString mDefaultShortcut;
|
||||||
|
GlobalKeyShortcut::Action * mShortcut;
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
|
void globalShortcutChanged(const QString &oldShortcut, const QString &newShortcut);
|
||||||
|
void shortcutChanged(const QString &value);
|
||||||
/*
|
/*
|
||||||
Saves settings in conf file.
|
Saves settings in conf file.
|
||||||
*/
|
*/
|
||||||
@ -63,7 +70,6 @@ private slots:
|
|||||||
void textButtonChanged(const QString &value);
|
void textButtonChanged(const QString &value);
|
||||||
void showTextChanged(bool value);
|
void showTextChanged(bool value);
|
||||||
void chooseMenuFile();
|
void chooseMenuFile();
|
||||||
void shortcutChanged(const QString &value);
|
|
||||||
void shortcutReset();
|
void shortcutReset();
|
||||||
void customFontChanged(bool value);
|
void customFontChanged(bool value);
|
||||||
void customFontSizeChanged(int value);
|
void customFontSizeChanged(int value);
|
||||||
|
@ -32,7 +32,9 @@
|
|||||||
Button::Button(QWidget * parent) :
|
Button::Button(QWidget * parent) :
|
||||||
QToolButton(parent)
|
QToolButton(parent)
|
||||||
{
|
{
|
||||||
setIcon(XdgIcon::fromTheme(QStringLiteral("drive-removable-media")));
|
//Note: don't use the QStringLiteral here as it is causing a SEGFAULT in static finalization time
|
||||||
|
//(the string is released upon our *.so removal, but the reference is still in held in libqtxdg...)
|
||||||
|
setIcon(XdgIcon::fromTheme(QLatin1String("drive-removable-media")));
|
||||||
setToolTip(tr("Removable media/devices manager"));
|
setToolTip(tr("Removable media/devices manager"));
|
||||||
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
||||||
}
|
}
|
||||||
|
@ -89,7 +89,9 @@ void MenuDiskItem::setMountStatus(bool mounted)
|
|||||||
|
|
||||||
void MenuDiskItem::updateMountStatus()
|
void MenuDiskItem::updateMountStatus()
|
||||||
{
|
{
|
||||||
static const QIcon icon = XdgIcon::fromTheme(mDevice.icon(), QStringLiteral("drive-removable-media"));
|
//Note: don't use the QStringLiteral here as it is causing a SEGFAULT in static finalization time
|
||||||
|
//(the string is released upon our *.so removal, but the reference is still in held in libqtxdg...)
|
||||||
|
static const QIcon icon = XdgIcon::fromTheme(mDevice.icon(), QLatin1String("drive-removable-media"));
|
||||||
|
|
||||||
if (mDevice.isValid())
|
if (mDevice.isValid())
|
||||||
{
|
{
|
||||||
|
@ -142,7 +142,7 @@ void LXQtTaskBar::dragEnterEvent(QDragEnterEvent* event)
|
|||||||
if (event->mimeData()->hasFormat(LXQtTaskGroup::mimeDataFormat()))
|
if (event->mimeData()->hasFormat(LXQtTaskGroup::mimeDataFormat()))
|
||||||
{
|
{
|
||||||
event->acceptProposedAction();
|
event->acceptProposedAction();
|
||||||
buttonMove(nullptr, LXQtTaskGroup::mimeDataData(event->mimeData()), event->pos());
|
buttonMove(nullptr, qobject_cast<LXQtTaskGroup *>(event->source()), event->pos());
|
||||||
} else
|
} else
|
||||||
event->ignore();
|
event->ignore();
|
||||||
QWidget::dragEnterEvent(event);
|
QWidget::dragEnterEvent(event);
|
||||||
@ -154,23 +154,22 @@ void LXQtTaskBar::dragEnterEvent(QDragEnterEvent* event)
|
|||||||
void LXQtTaskBar::dragMoveEvent(QDragMoveEvent * event)
|
void LXQtTaskBar::dragMoveEvent(QDragMoveEvent * event)
|
||||||
{
|
{
|
||||||
//we don't get any dragMoveEvents if dragEnter wasn't accepted
|
//we don't get any dragMoveEvents if dragEnter wasn't accepted
|
||||||
buttonMove(nullptr, LXQtTaskGroup::mimeDataData(event->mimeData()), event->pos());
|
buttonMove(nullptr, qobject_cast<LXQtTaskGroup *>(event->source()), event->pos());
|
||||||
QWidget::dragMoveEvent(event);
|
QWidget::dragMoveEvent(event);
|
||||||
}
|
}
|
||||||
|
|
||||||
/************************************************
|
/************************************************
|
||||||
|
|
||||||
************************************************/
|
************************************************/
|
||||||
void LXQtTaskBar::buttonMove(LXQtTaskGroup * dst, QString const & srcWindow, QPoint const & pos)
|
void LXQtTaskBar::buttonMove(LXQtTaskGroup * dst, LXQtTaskGroup * src, QPoint const & pos)
|
||||||
{
|
{
|
||||||
LXQtTaskGroup *src_group = mGroupsHash.value(srcWindow, nullptr);
|
int src_index;
|
||||||
if (!src_group)
|
if (!src || -1 == (src_index = mLayout->indexOf(src)))
|
||||||
{
|
{
|
||||||
qDebug() << "Dropped invalid";
|
qDebug() << "Dropped invalid";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const int src_index = mLayout->indexOf(src_group);
|
|
||||||
const int size = mLayout->count();
|
const int size = mLayout->count();
|
||||||
Q_ASSERT(0 < size);
|
Q_ASSERT(0 < size);
|
||||||
//dst is nullptr in case the drop occured on empty space in taskbar
|
//dst is nullptr in case the drop occured on empty space in taskbar
|
||||||
@ -245,8 +244,8 @@ void LXQtTaskBar::addWindow(WId window, QString const & groupId)
|
|||||||
connect(group, SIGNAL(visibilityChanged(bool)), this, SLOT(refreshPlaceholderVisibility()));
|
connect(group, SIGNAL(visibilityChanged(bool)), this, SLOT(refreshPlaceholderVisibility()));
|
||||||
connect(group, &LXQtTaskGroup::popupShown, this, &LXQtTaskBar::groupPopupShown);
|
connect(group, &LXQtTaskGroup::popupShown, this, &LXQtTaskBar::groupPopupShown);
|
||||||
connect(group, SIGNAL(windowDisowned(WId)), this, SLOT(refreshTaskList()));
|
connect(group, SIGNAL(windowDisowned(WId)), this, SLOT(refreshTaskList()));
|
||||||
connect(group, &LXQtTaskButton::dragging, this, [this] (QString const & mimeWindow, QPoint const & pos) {
|
connect(group, &LXQtTaskButton::dragging, this, [this] (QObject * dragSource, QPoint const & pos) {
|
||||||
buttonMove(qobject_cast<LXQtTaskGroup *>(sender()), mimeWindow, pos);
|
buttonMove(qobject_cast<LXQtTaskGroup *>(sender()), qobject_cast<LXQtTaskGroup *>(dragSource), pos);
|
||||||
});
|
});
|
||||||
|
|
||||||
mLayout->addWidget(group);
|
mLayout->addWidget(group);
|
||||||
|
@ -95,7 +95,7 @@ private slots:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
void addWindow(WId window, QString const & groupId);
|
void addWindow(WId window, QString const & groupId);
|
||||||
void buttonMove(LXQtTaskGroup * dst, QString const & srcWindow, QPoint const & pos);
|
void buttonMove(LXQtTaskGroup * dst, LXQtTaskGroup * src, QPoint const & pos);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QHash<QString, LXQtTaskGroup*> mGroupsHash;
|
QHash<QString, LXQtTaskGroup*> mGroupsHash;
|
||||||
|
@ -70,17 +70,6 @@ void LeftAlignedTextStyle::drawItemText(QPainter * painter, const QRect & rect,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/************************************************
|
|
||||||
|
|
||||||
************************************************/
|
|
||||||
QString LXQtTaskButton::mimeDataData(QMimeData const * mime)
|
|
||||||
{
|
|
||||||
QString data;
|
|
||||||
QDataStream stream(mime->data(mimeDataFormat()));
|
|
||||||
stream >> data;
|
|
||||||
return data;
|
|
||||||
}
|
|
||||||
|
|
||||||
/************************************************
|
/************************************************
|
||||||
|
|
||||||
************************************************/
|
************************************************/
|
||||||
@ -173,7 +162,7 @@ void LXQtTaskButton::dragEnterEvent(QDragEnterEvent *event)
|
|||||||
event->acceptProposedAction();
|
event->acceptProposedAction();
|
||||||
if (event->mimeData()->hasFormat(mimeDataFormat()))
|
if (event->mimeData()->hasFormat(mimeDataFormat()))
|
||||||
{
|
{
|
||||||
emit dragging(mimeDataData(event->mimeData()), event->pos());
|
emit dragging(event->source(), event->pos());
|
||||||
setAttribute(Qt::WA_UnderMouse, false);
|
setAttribute(Qt::WA_UnderMouse, false);
|
||||||
} else
|
} else
|
||||||
{
|
{
|
||||||
@ -187,7 +176,7 @@ void LXQtTaskButton::dragMoveEvent(QDragMoveEvent * event)
|
|||||||
{
|
{
|
||||||
if (event->mimeData()->hasFormat(mimeDataFormat()))
|
if (event->mimeData()->hasFormat(mimeDataFormat()))
|
||||||
{
|
{
|
||||||
emit dragging(mimeDataData(event->mimeData()), event->pos());
|
emit dragging(event->source(), event->pos());
|
||||||
setAttribute(Qt::WA_UnderMouse, false);
|
setAttribute(Qt::WA_UnderMouse, false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -203,7 +192,7 @@ void LXQtTaskButton::dropEvent(QDropEvent *event)
|
|||||||
mDNDTimer->stop();
|
mDNDTimer->stop();
|
||||||
if (event->mimeData()->hasFormat(mimeDataFormat()))
|
if (event->mimeData()->hasFormat(mimeDataFormat()))
|
||||||
{
|
{
|
||||||
emit dropped(mimeDataData(event->mimeData()), event->pos());
|
emit dropped(event->source(), event->pos());
|
||||||
setAttribute(Qt::WA_UnderMouse, false);
|
setAttribute(Qt::WA_UnderMouse, false);
|
||||||
}
|
}
|
||||||
QToolButton::dropEvent(event);
|
QToolButton::dropEvent(event);
|
||||||
@ -266,7 +255,20 @@ void LXQtTaskButton::mouseMoveEvent(QMouseEvent* event)
|
|||||||
QDrag *drag = new QDrag(this);
|
QDrag *drag = new QDrag(this);
|
||||||
drag->setMimeData(mimeData());
|
drag->setMimeData(mimeData());
|
||||||
QIcon ico = icon();
|
QIcon ico = icon();
|
||||||
drag->setPixmap(ico.pixmap(ico.actualSize({32, 32})));
|
QPixmap img = ico.pixmap(ico.actualSize({32, 32}));
|
||||||
|
drag->setPixmap(img);
|
||||||
|
switch (parentTaskBar()->panel()->position())
|
||||||
|
{
|
||||||
|
case ILXQtPanel::PositionLeft:
|
||||||
|
case ILXQtPanel::PositionTop:
|
||||||
|
drag->setHotSpot({0, 0});
|
||||||
|
break;
|
||||||
|
case ILXQtPanel::PositionRight:
|
||||||
|
case ILXQtPanel::PositionBottom:
|
||||||
|
drag->setHotSpot(img.rect().bottomRight());
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
sDraggging = true;
|
sDraggging = true;
|
||||||
drag->exec();
|
drag->exec();
|
||||||
|
|
||||||
|
@ -85,7 +85,6 @@ public:
|
|||||||
|
|
||||||
void refreshIconGeometry(QRect const & geom);
|
void refreshIconGeometry(QRect const & geom);
|
||||||
static QString mimeDataFormat() { return QLatin1String("lxqt/lxqttaskbutton"); }
|
static QString mimeDataFormat() { return QLatin1String("lxqt/lxqttaskbutton"); }
|
||||||
static QString mimeDataData(QMimeData const * mime);
|
|
||||||
/*! \return true if this buttom received DragEnter event (and no DragLeave event yet)
|
/*! \return true if this buttom received DragEnter event (and no DragLeave event yet)
|
||||||
* */
|
* */
|
||||||
bool hasDragAndDropHover() const;
|
bool hasDragAndDropHover() const;
|
||||||
@ -136,8 +135,8 @@ private slots:
|
|||||||
void activateWithDraggable();
|
void activateWithDraggable();
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void dropped(QString const & mimeWindow, QPoint const & pos);
|
void dropped(QObject * dragSource, QPoint const & pos);
|
||||||
void dragging(QString const & mimeWindow, QPoint const & pos);
|
void dragging(QObject * dragSource, QPoint const & pos);
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef QHash<WId,LXQtTaskButton*> LXQtTaskButtonHash;
|
typedef QHash<WId,LXQtTaskButton*> LXQtTaskButtonHash;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user