~ubuntu-branches/ubuntu/trusty/scribus/trusty

« back to all changes in this revision

Viewing changes to scribus/scfilewidget.cpp

  • Committer: Package Import Robot
  • Author(s): Colin Watson
  • Date: 2013-05-16 20:34:07 UTC
  • mfrom: (1.1.13) (32.1.2 saucy-proposed)
  • Revision ID: package-import@ubuntu.com-20130516203407-ztj7ebsivoo41dih
Tags: 1.4.2.dfsg+r18267-1ubuntu2
Avoid qreal/double type clashes on ARM.

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
for which a new license (GPL+exception) is in place.
6
6
*/
7
7
#include <QPushButton>
 
8
#include <QListView>
8
9
#include <QUrl>
9
10
 
 
11
#include "scescapecatcher.h"
10
12
#include "scfilewidget.h"
11
13
 
12
14
 
18
20
        setViewMode(QFileDialog::List);
19
21
        setWindowFlags(Qt::Widget);
20
22
 
21
 
 
22
23
#ifdef Q_OS_MAC
23
24
        QList<QUrl> urls;
24
25
        QUrl computer(QUrl::fromLocalFile(QLatin1String("")));
30
31
        //desktop too?  QUrl computer(QUrl::fromLocalFile(QDesktopServices::storageLocation(QDesktopServices::DesktopLocation)));
31
32
        setSidebarUrls(urls);
32
33
#endif
 
34
 
 
35
        ScEscapeCatcher* keyCatcher = new ScEscapeCatcher(this);
 
36
        QList<QListView *> lv = findChildren<QListView *>();
 
37
        QListIterator<QListView *> lvi(lv);
 
38
        while (lvi.hasNext())
 
39
                lvi.next()->installEventFilter(keyCatcher);
 
40
        connect(keyCatcher, SIGNAL(escapePressed()), this, SLOT(reject()));
 
41
 
33
42
        QList<QPushButton *> b = findChildren<QPushButton *>();
34
43
        QListIterator<QPushButton *> i(b);
35
44
        while (i.hasNext())