~ubuntu-branches/debian/stretch/apper/stretch

« back to all changes in this revision

Viewing changes to Apper/MainUi.cpp

  • Committer: Package Import Robot
  • Author(s): Matthias Klumpp
  • Date: 2013-07-30 12:34:46 UTC
  • mfrom: (1.1.4)
  • Revision ID: package-import@ubuntu.com-20130730123446-cgzujaj03pc61drn
Tags: 0.8.1-1
* New upstream release: 0.8.1
* Depend on software-properties-kde instead of suggesting it (Closes: #696583)
* Add patch to make AppStream loading more failsafe

Show diffs side-by-side

added added

removed removed

Lines of Context:
25
25
#include <KConfig>
26
26
#include <KCModuleProxy>
27
27
 
28
 
MainUi::MainUi(QWidget *parent)
29
 
  : KCMultiDialog(parent),
 
28
MainUi::MainUi(QWidget *parent) :
 
29
    KCMultiDialog(parent),
30
30
    m_apperModule(0)
31
31
{
32
32
    setCaption(QString());
39
39
    // Set Apply and Cancel buttons
40
40
    setButtons(KDialog::Apply /*| KDialog::Help*/ | KDialog::Default | KDialog::Reset);
41
41
 
42
 
    KPageWidgetItem *page = addModule("kcm_apper.desktop");
 
42
    KPageWidgetItem *page = addModule(QLatin1String("kcm_apper.desktop"),
 
43
                                      QStringList() << QLatin1String("apper"));
43
44
    if (page) {
44
45
        KCModuleProxy *proxy = static_cast<KCModuleProxy*>(page->widget());
45
46
        if (proxy) {
46
47
            m_apperModule = proxy->realModule();
 
48
            connect(m_apperModule, SIGNAL(caption(QString)),
 
49
                    this, SLOT(setCaption(QString)));
47
50
        }
48
51
    } else {
49
52
        kWarning() << "Could not load kcm_apper.desktop!";