author | alwin <alwin> | 2005-03-24 13:28:49 (UTC) |
---|---|---|
committer | alwin <alwin> | 2005-03-24 13:28:49 (UTC) |
commit | 29da9a4477210843435cbea3ede0d520775fe1a5 (patch) (side-by-side diff) | |
tree | 487b26273bcdb8e29cd3f591955e8469d01c0da7 | |
parent | 4fbd94e2fd6432bb15e24e40be59426b309cbb9d (diff) | |
download | opie-29da9a4477210843435cbea3ede0d520775fe1a5.zip opie-29da9a4477210843435cbea3ede0d520775fe1a5.tar.gz opie-29da9a4477210843435cbea3ede0d520775fe1a5.tar.bz2 |
the filesystem-menu will executed when click on the filsystem-button
not when hold the pen on it.
-rw-r--r-- | libopie2/opieui/fileselector/ofileselector.cpp | 18 | ||||
-rw-r--r-- | libopie2/opieui/fileselector/ofileselector_p.h | 2 |
2 files changed, 14 insertions, 6 deletions
diff --git a/libopie2/opieui/fileselector/ofileselector.cpp b/libopie2/opieui/fileselector/ofileselector.cpp index 74aca96..dbba4b9 100644 --- a/libopie2/opieui/fileselector/ofileselector.cpp +++ b/libopie2/opieui/fileselector/ofileselector.cpp @@ -69,4 +69,4 @@ namespace Internal { static inline QString createNewPath(const QString& base, const QString &ending) { - return base == QString::fromLatin1("/") ? - base + ending : base + "/" + ending; + return base == QString::fromLatin1("/") ? + base + ending : base + "/" + ending; } @@ -290,3 +290,3 @@ QString OFileSelectorItem::key( int id, bool )const QString ke; - + /* @@ -309,3 +309,3 @@ QString OFileSelectorItem::key( int id, bool )const }else if(id == 2) { - return text(2).rightJustify(20, '0'); + return text(2).rightJustify(20, '0'); }else @@ -365,2 +365,3 @@ OFileViewFileListView::OFileViewFileListView( QWidget* parent, const QString& st + m_fsButton = btn; /* let's fill device parts */ @@ -382,4 +383,3 @@ OFileViewFileListView::OFileViewFileListView( QWidget* parent, const QString& st - - btn->setPopup( pop ); + connect(btn,SIGNAL(pressed()),this,SLOT(slotFSpressed())); @@ -407,2 +407,8 @@ OFileViewFileListView::OFileViewFileListView( QWidget* parent, const QString& st +void OFileViewFileListView::slotFSpressed() +{ + m_fsPop->exec(QPoint( QCursor::pos().x(), QCursor::pos().y())); + m_fsButton->setDown(false); +} + OFileViewFileListView::~OFileViewFileListView() diff --git a/libopie2/opieui/fileselector/ofileselector_p.h b/libopie2/opieui/fileselector/ofileselector_p.h index 15db916..94216a0 100644 --- a/libopie2/opieui/fileselector/ofileselector_p.h +++ b/libopie2/opieui/fileselector/ofileselector_p.h @@ -166,2 +166,3 @@ private slots: void slotFSActivated(int); + void slotFSpressed(); @@ -179,2 +180,3 @@ private: QToolButton *m_btnNew, *m_btnClose; + QToolButton *m_fsButton; void connectSlots(); |