author | zecke <zecke> | 2004-03-14 18:05:28 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-03-14 18:05:28 (UTC) |
commit | 9e54b8bd8343af7c301da17d82596d6027e53309 (patch) (unidiff) | |
tree | 693613ff9f1a0f3415e0623e636d47ac4798da2d /core/multimedia/opieplayer/inputDialog.cpp | |
parent | 98bbe5561e8e1a862e19a3d0a0d49ed90ef15b54 (diff) | |
download | opie-9e54b8bd8343af7c301da17d82596d6027e53309.zip opie-9e54b8bd8343af7c301da17d82596d6027e53309.tar.gz opie-9e54b8bd8343af7c301da17d82596d6027e53309.tar.bz2 |
OpiePlayer -> ODP
Diffstat (limited to 'core/multimedia/opieplayer/inputDialog.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/multimedia/opieplayer/inputDialog.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/multimedia/opieplayer/inputDialog.cpp b/core/multimedia/opieplayer/inputDialog.cpp index 38b8f53..44a1cdd 100644 --- a/core/multimedia/opieplayer/inputDialog.cpp +++ b/core/multimedia/opieplayer/inputDialog.cpp | |||
@@ -1,57 +1,58 @@ | |||
1 | #include "inputDialog.h" | 1 | #include "inputDialog.h" |
2 | 2 | ||
3 | #include <qpe/resource.h> | 3 | #include <qpe/resource.h> |
4 | 4 | ||
5 | #include <opie/ofiledialog.h> | 5 | #include <opie2/ofiledialog.h> |
6 | 6 | ||
7 | #include <qlineedit.h> | 7 | #include <qlineedit.h> |
8 | #include <qpushbutton.h> | 8 | #include <qpushbutton.h> |
9 | 9 | ||
10 | using namespace Opie::Ui; | ||
10 | InputDialog::InputDialog( QWidget* parent, const char* name, bool modal, WFlags fl ) | 11 | InputDialog::InputDialog( QWidget* parent, const char* name, bool modal, WFlags fl ) |
11 | : QDialog( parent, name, modal, fl ) { | 12 | : QDialog( parent, name, modal, fl ) { |
12 | if ( !name ) { | 13 | if ( !name ) { |
13 | setName( "InputDialog" ); | 14 | setName( "InputDialog" ); |
14 | } | 15 | } |
15 | resize( 234, 115); | 16 | resize( 234, 115); |
16 | setMaximumSize( QSize( 240, 40)); | 17 | setMaximumSize( QSize( 240, 40)); |
17 | setCaption( tr( name ) ); | 18 | setCaption( tr( name ) ); |
18 | 19 | ||
19 | QPushButton *browserButton; | 20 | QPushButton *browserButton; |
20 | browserButton = new QPushButton( Resource::loadIconSet("fileopen"),"",this,"BrowseButton"); | 21 | browserButton = new QPushButton( Resource::loadIconSet("fileopen"),"",this,"BrowseButton"); |
21 | browserButton->setGeometry( QRect( 205, 10, 22, 22)); | 22 | browserButton->setGeometry( QRect( 205, 10, 22, 22)); |
22 | connect( browserButton, SIGNAL(released()),this,SLOT(browse())); | 23 | connect( browserButton, SIGNAL(released()),this,SLOT(browse())); |
23 | LineEdit1 = new QLineEdit( this, "LineEdit1" ); | 24 | LineEdit1 = new QLineEdit( this, "LineEdit1" ); |
24 | LineEdit1->setGeometry( QRect( 4, 10, 190, 22 ) ); | 25 | LineEdit1->setGeometry( QRect( 4, 10, 190, 22 ) ); |
25 | LineEdit1->setFocus(); | 26 | LineEdit1->setFocus(); |
26 | } | 27 | } |
27 | /* | 28 | /* |
28 | * return the current text(input) | 29 | * return the current text(input) |
29 | */ | 30 | */ |
30 | QString InputDialog::text() const { | 31 | QString InputDialog::text() const { |
31 | return LineEdit1->text(); | 32 | return LineEdit1->text(); |
32 | } | 33 | } |
33 | /* | 34 | /* |
34 | * Destroys the object and frees any allocated resources | 35 | * Destroys the object and frees any allocated resources |
35 | */ | 36 | */ |
36 | InputDialog::~InputDialog() { | 37 | InputDialog::~InputDialog() { |
37 | } | 38 | } |
38 | 39 | ||
39 | void InputDialog::browse() { | 40 | void InputDialog::browse() { |
40 | 41 | ||
41 | MimeTypes types; | 42 | MimeTypes types; |
42 | QStringList audio, video, all; | 43 | QStringList audio, video, all; |
43 | audio << "audio/*"; | 44 | audio << "audio/*"; |
44 | audio << "playlist/plain"; | 45 | audio << "playlist/plain"; |
45 | audio << "audio/x-mpegurl"; | 46 | audio << "audio/x-mpegurl"; |
46 | 47 | ||
47 | video << "video/*"; | 48 | video << "video/*"; |
48 | video << "playlist/plain"; | 49 | video << "playlist/plain"; |
49 | 50 | ||
50 | all += audio; | 51 | all += audio; |
51 | all += video; | 52 | all += video; |
52 | types.insert("All Media Files", all ); | 53 | types.insert("All Media Files", all ); |
53 | types.insert("Audio", audio ); | 54 | types.insert("Audio", audio ); |
54 | types.insert("Video", video ); | 55 | types.insert("Video", video ); |
55 | 56 | ||
56 | QString str = OFileDialog::getOpenFileName( 1,"/","", types, 0 ); | 57 | QString str = OFileDialog::getOpenFileName( 1,"/","", types, 0 ); |
57 | LineEdit1->setText(str); | 58 | LineEdit1->setText(str); |