~ubuntu-branches/ubuntu/quantal/psi/quantal

« back to all changes in this revision

Viewing changes to src/psitoolbar.h

  • Committer: Bazaar Package Importer
  • Author(s): Jan Niehusmann
  • Date: 2008-08-28 18:46:52 UTC
  • mfrom: (1.2.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20080828184652-iiik12dl91nq7cdi
Tags: 0.12-2
Uploading to unstable (Closes: Bug#494352)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
2
 * psitoolbar.h - the Psi toolbar class
3
 
 * Copyright (C) 2003  Michail Pishchagin
 
3
 * Copyright (C) 2003-2008  Michail Pishchagin
4
4
 *
5
5
 * This program is free software; you can redistribute it and/or
6
6
 * modify it under the terms of the GNU General Public License
21
21
#ifndef PSITOOLBAR_H
22
22
#define PSITOOLBAR_H
23
23
 
24
 
#include <q3toolbar.h>
 
24
#include <QToolBar>
 
25
 
 
26
class QContextMenuEvent;
 
27
 
 
28
class ToolbarPrefs;
 
29
class PsiOptions;
25
30
 
26
31
#include "psiactionlist.h"
27
 
#include "common.h" // Options + ToolbarPrefs
28
 
 
29
 
class PsiCon;
30
 
class QContextMenuEvent;
31
 
 
32
 
class PsiToolBar : public Q3ToolBar
 
32
 
 
33
class PsiToolBar : public QToolBar
33
34
{
34
35
        Q_OBJECT
35
36
 
36
37
public:
37
 
        PsiToolBar(const QString& label, Q3MainWindow* mainWindow, PsiCon* psi);
 
38
        PsiToolBar(const QString& base, QMainWindow* mainWindow, MetaActionList* actionList);
38
39
        ~PsiToolBar();
39
40
 
40
 
        PsiActionList::ActionsType type() const;
41
 
        void setType( PsiActionList::ActionsType );
42
 
        void initialize( Options::ToolbarPrefs &, bool createUniqueActions );
43
 
 
44
 
        QString group() const;
45
 
        int groupIndex() const;
46
 
        void setGroup( QString group, int index );
47
 
        
48
 
        bool isCustomizeable() const;
49
 
        void setCustomizeable( bool );
50
 
 
51
 
        bool isMoveable() const;
52
 
        void setMoveable( bool );
53
 
        
 
41
        void initialize();
 
42
        void updateVisibility();
 
43
 
 
44
        static void structToOptions(PsiOptions* options, const ToolbarPrefs& s);
 
45
 
54
46
signals:
55
 
        void registerAction( IconAction * );
 
47
        void customize();
56
48
 
57
49
protected:
58
 
        void contextMenuEvent(QContextMenuEvent *e);
 
50
        void contextMenuEvent(QContextMenuEvent* e);
59
51
 
60
52
private:
61
 
        class Private;
62
 
        Private *d;
 
53
        MetaActionList* actionList_;
 
54
        QAction* customizeAction_;
 
55
        QString base_;
63
56
};
64
57
 
65
58
#endif