ended work on ptm-desktop-panel

This commit is contained in:
arcan1s
2014-07-09 09:42:58 +04:00
parent a81cbe3d9c
commit 662b952961
3 changed files with 105 additions and 4 deletions

View File

@ -28,6 +28,29 @@
class QGraphicsLinearLayout;
class DesktopPanel;
class CustomPlasmaLabel : public Plasma::Label
{
Q_OBJECT
public:
CustomPlasmaLabel(DesktopPanel *wid, const int num);
~CustomPlasmaLabel();
int getNumber();
protected:
void mousePressEvent(QGraphicsSceneMouseEvent *event);
private:
// debug
bool debug;
// variables
int number;
DesktopPanel *widget;
};
class DesktopPanel : public Plasma::Applet
{
@ -44,10 +67,11 @@ public slots:
// configuration interface
void configAccepted();
void configChanged();
// event
int setCurrentDesktop(const int number);
private slots:
void reinit();
void setCurrentDesktop();
protected:
void createConfigurationInterface(KConfigDialog *parent);
@ -58,7 +82,7 @@ private:
void updateText();
// ui
QGraphicsLinearLayout *layout;
QList<Plasma::Label *> labels;
QList<CustomPlasmaLabel *> labels;
// debug
bool debug;
// data engine