278c511d4f
his part of the patch, works fine but there's just the re-check needed to be added so when the effect for tooltips changes, the deco's tooltips take this as well. There are no new strings except the Un-Sticky tooltip, all others are translated. thd@kde.org agreed on the strings. svn path=/trunk/kdebase/kwin/; revision=104585
64 lines
1.3 KiB
C++
64 lines
1.3 KiB
C++
#ifndef __MWMCLIENT_H
|
|
#define __MWMCLIENT_H
|
|
|
|
#include <qbutton.h>
|
|
#include <qbitmap.h>
|
|
#include <kpixmap.h>
|
|
#include "../../client.h"
|
|
#include "../../kwinbutton.h"
|
|
class QLabel;
|
|
class QSpacerItem;
|
|
|
|
namespace KWinInternal {
|
|
|
|
class MwmClient;
|
|
|
|
enum Buttons { BtnMenu=0, BtnIconify=1, BtnMax=2 };
|
|
|
|
class MwmButton : public KWinInternal::KWinButton
|
|
{
|
|
public:
|
|
MwmButton( MwmClient* parent=0, const char* name=0, int btnType=0,
|
|
const QString& tip=NULL );
|
|
void reset();
|
|
|
|
protected:
|
|
virtual void drawButton( QPainter *p );
|
|
|
|
private:
|
|
int m_btnType;
|
|
Client* m_parent;
|
|
};
|
|
|
|
class MwmClient : public KWinInternal::Client
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
MwmClient( Workspace* ws, WId w, QWidget* parent=0, const char* name=0 );
|
|
~MwmClient() {};
|
|
|
|
protected:
|
|
void resizeEvent( QResizeEvent* );
|
|
void paintEvent( QPaintEvent* );
|
|
|
|
void mouseDoubleClickEvent( QMouseEvent* );
|
|
void init();
|
|
void captionChange( const QString& );
|
|
void maximizeChange( bool m );
|
|
void activeChange( bool );
|
|
MousePosition mousePosition( const QPoint& p ) const;
|
|
|
|
protected slots:
|
|
void slotReset();
|
|
void slotMaximize();
|
|
void menuButtonPressed();
|
|
|
|
private:
|
|
MwmButton* button[3];
|
|
QSpacerItem* titlebar;
|
|
};
|
|
|
|
};
|
|
|
|
#endif
|
|
|