~ubuntu-branches/ubuntu/oneiric/kdelibs/oneiric

« back to all changes in this revision

Viewing changes to .pc/kubuntu_55_printer_sharing.diff/kdeprint/management/kmmainview.h

  • Committer: Bazaar Package Importer
  • Author(s): Felix Geyer
  • Date: 2010-10-15 19:20:42 UTC
  • mfrom: (1.1.19 sid)
  • Revision ID: james.westby@ubuntu.com-20101015192042-jv1fhj33n4f5b398
Tags: 4:3.5.10.dfsg.1-5ubuntu1
* Merge from Debian unstable. Remaining Ubuntu changes:
  - make sure control and control.in are in sync
  - --with-distribution="Kubuntu (`lsb_release --codename --short`)
    $(DEB_VERSION)"
  - binary-install/kdelibs-data installs aboutkde-kubuntu.png.uu and
    cr*-device-system.png.uu
  - don't build-dep on libgamin-dev, libfam-dev
  - stop kdelibs4-dev depending on gamin/fam
  - don't install .svgz icons, docs or all_languages in kdelibs-data.install
  - rosetta support in rules common-install-prehook-impl:: [and
    common-post-build-arch:: ?] and include debian/kubuntu-desktop-i18n/
  - build-dep on: gettext-kde, kdesdk-scripts, lsb-release, base-files, sudo
  - cdbs build-dep 0.4.41ubuntu2
  - kdelibs4-dev depends on gettext-kde, kdesdk-scripts
  - copy debian/icons over
  - Make kdelibs4c2a depend on launchpad-integration, sudo.  Recommends on
    xdg-user-dirs
  - Remove 19_debianize_useragent.diff (changed to
    kubuntu_19_debianize_useragent.diff) s/Debian/Kubuntu
  - remove kdelibs4c2a depends on menu-xdg
  - include kubuntu_01_kdepot.diff and kde.pot in debian/patches/common
  - use a local copy of kde.mk without the common-install-prehook-impl::
    rule; edit debian-qt-kde.mk to include debian/cdbs/kde.mk
  - build with --with-sudo-kdesu-backend and build-dep on sudo and make
    kdelibs4c2a depend on sudo
  - kdelibs-data.install : Add nzb mimetype
  - Make kdelibs4-dev replace more recent kdelibs4c2a for overlapping files
  - remove /usr/bin/preparetips, arts files and ksvntopng from
    kdelibs4-dev.install
  - Drop the package kdelibs4-doc completely. It contained API documentation
    which is now obsolete, but still available via api.kde.org.
  - make sure control and control.in are in sync
  - in debian/rule remove .pot files outside .po directory
  - 97_automake_cleanup.diff becomes kubuntu_97_automake_cleanup.diff
  - Remove libarts1-dev from build-depends and kdelibs4-dev depends from
    control.in
* Drop kubuntu_98_fix_khc_invocation.diff, replaced by
  68_support_khelpcenter4.diff
* Drop kubuntu_97_automake_cleanup.diff, replaced by 97_automake_cleanup.diff
* Re-add security_05_XMLHttpRequest_vulnerability.diff which has been
  accidentally dropped
* Fix FTBFS, in debian/rules:
  - Add -Wl,--add-needed to LDFLAGS
  - Disable parallel building

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 *  This file is part of the KDE libraries
 
3
 *  Copyright (c) 2001 Michael Goffioul <kdeprint@swing.be>
 
4
 *
 
5
 *  This library is free software; you can redistribute it and/or
 
6
 *  modify it under the terms of the GNU Library General Public
 
7
 *  License version 2 as published by the Free Software Foundation.
 
8
 *
 
9
 *  This library is distributed in the hope that it will be useful,
 
10
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 
11
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
12
 *  Library General Public License for more details.
 
13
 *
 
14
 *  You should have received a copy of the GNU Library General Public License
 
15
 *  along with this library; see the file COPYING.LIB.  If not, write to
 
16
 *  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
 
17
 *  Boston, MA 02110-1301, USA.
 
18
 **/
 
19
 
 
20
#ifndef KMMAINVIEW_H
 
21
#define KMMAINVIEW_H
 
22
 
 
23
#if !defined( _KDEPRINT_COMPILE ) && defined( __GNUC__ )
 
24
#warning internal header, do not use except if you are a KDEPrint developer
 
25
#endif
 
26
 
 
27
#include <qwidget.h>
 
28
#include <kdeprint/kpreloadobject.h>
 
29
#include <kmainwindow.h>
 
30
 
 
31
class KMManager;
 
32
class KMPrinterView;
 
33
class KMPrinter;
 
34
class KMPages;
 
35
class KActionCollection;
 
36
class QPopupMenu;
 
37
class QTimer;
 
38
class QSplitter;
 
39
class KToolBar;
 
40
class KAction;
 
41
class PluginComboBox;
 
42
class QBoxLayout;
 
43
class MessageWindow;
 
44
class QMenuBar;
 
45
 
 
46
/**
 
47
 * @internal
 
48
 * This class is internal to KDEPrint and is not intended to be
 
49
 * used outside it. Please do not make use of this header, except
 
50
 * if you're a KDEPrint developer. The API might change in the
 
51
 * future and binary compatibility might be broken.
 
52
 */
 
53
class KDEPRINT_EXPORT KMMainView : public QWidget, public KPReloadObject
 
54
{
 
55
        Q_OBJECT
 
56
public:
 
57
        KMMainView(QWidget *parent = 0, const char *name = 0, KActionCollection *coll = 0);
 
58
        ~KMMainView();
 
59
 
 
60
        void setOrientation(int);
 
61
        int orientation() const;
 
62
        void setViewType(int);
 
63
        int viewType() const;
 
64
        void enableToolbar(bool on = true);
 
65
        KAction* action(const char *name);
 
66
        void showPrinterInfos(bool on);
 
67
        bool printerInfosShown() const;
 
68
 
 
69
public slots:
 
70
        void slotTimer();
 
71
        void slotShowPrinterInfos(bool);
 
72
        void slotChangePrinterState();
 
73
        void slotRemove();
 
74
        void slotConfigure();
 
75
        void slotAdd();
 
76
        void slotHardDefault();
 
77
        void slotSoftDefault();
 
78
        void slotTest();
 
79
        void slotServerRestart();
 
80
        void slotServerConfigure();
 
81
        void slotManagerConfigure();
 
82
        void slotAddSpecial();
 
83
        void slotRefresh();
 
84
        void slotToolSelected(int);
 
85
        void slotToggleFilter(bool);
 
86
        void slotHelp();
 
87
 
 
88
protected slots:
 
89
        void slotPrinterSelected(const QString&);
 
90
        void slotRightButtonClicked(const QString&, const QPoint&);
 
91
        void slotToggleToolBar(bool);
 
92
        void slotToggleMenuBar(bool);
 
93
        void slotChangeView(int);
 
94
        void slotChangeDirection(int);
 
95
        void slotUpdatePossible( bool );
 
96
        void slotInit();
 
97
 
 
98
protected:
 
99
        void initActions();
 
100
        void showErrorMsg(const QString& msg, bool usemgr = true);
 
101
        void restoreSettings();
 
102
        void saveSettings();
 
103
        void loadParameters();
 
104
        void reload();
 
105
        void configChanged();
 
106
        //void aboutToReload();
 
107
        void loadPluginActions();
 
108
        void removePluginActions();
 
109
        void createMessageWindow( const QString&, int delay = 500 );
 
110
        void destroyMessageWindow();
 
111
        void reset( const QString& msg = QString::null, bool useDelay = true, bool holdTimer = true );
 
112
 
 
113
private:
 
114
        KMPrinterView   *m_printerview;
 
115
        KMPages         *m_printerpages;
 
116
        QPopupMenu      *m_pop;
 
117
        KActionCollection       *m_actions;
 
118
        KMPrinter       *m_current;
 
119
        KToolBar        *m_toolbar;
 
120
        PluginComboBox  *m_plugin;
 
121
        int             m_pactionsindex;
 
122
        QStringList     m_toollist;
 
123
        bool            m_first;
 
124
        QBoxLayout      *m_boxlayout;
 
125
        class KMainWindowPrivate;
 
126
        KMainWindowPrivate *d;
 
127
        KToolBar *m_menubar;
 
128
};
 
129
 
 
130
KDEPRINT_EXPORT int kdeprint_management_add_printer_wizard( QWidget* parent );
 
131
 
 
132
#endif