Diffstat (limited to 'core/multimedia/opieplayer/inputDialog.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/multimedia/opieplayer/inputDialog.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/core/multimedia/opieplayer/inputDialog.cpp b/core/multimedia/opieplayer/inputDialog.cpp index 44a1cdd..b76004e 100644 --- a/core/multimedia/opieplayer/inputDialog.cpp +++ b/core/multimedia/opieplayer/inputDialog.cpp | |||
@@ -1,46 +1,47 @@ | |||
1 | #include "inputDialog.h" | 1 | #include "inputDialog.h" |
2 | 2 | ||
3 | #include <qpe/resource.h> | ||
4 | |||
5 | #include <opie2/ofiledialog.h> | 3 | #include <opie2/ofiledialog.h> |
4 | #include <opie2/oresource.h> | ||
5 | |||
6 | #include <qpe/applnk.h> | ||
6 | 7 | ||
7 | #include <qlineedit.h> | 8 | #include <qlineedit.h> |
8 | #include <qpushbutton.h> | 9 | #include <qpushbutton.h> |
9 | 10 | ||
10 | using namespace Opie::Ui; | 11 | using namespace Opie::Ui; |
11 | InputDialog::InputDialog( QWidget* parent, const char* name, bool modal, WFlags fl ) | 12 | InputDialog::InputDialog( QWidget* parent, const char* name, bool modal, WFlags fl ) |
12 | : QDialog( parent, name, modal, fl ) { | 13 | : QDialog( parent, name, modal, fl ) { |
13 | if ( !name ) { | 14 | if ( !name ) { |
14 | setName( "InputDialog" ); | 15 | setName( "InputDialog" ); |
15 | } | 16 | } |
16 | resize( 234, 115); | 17 | resize( 234, 115); |
17 | setMaximumSize( QSize( 240, 40)); | 18 | setMaximumSize( QSize( 240, 40)); |
18 | setCaption( tr( name ) ); | 19 | setCaption( tr( name ) ); |
19 | 20 | ||
20 | QPushButton *browserButton; | 21 | QPushButton *browserButton; |
21 | browserButton = new QPushButton( Resource::loadIconSet("fileopen"),"",this,"BrowseButton"); | 22 | browserButton = new QPushButton( Opie::Core::OResource::loadPixmap("fileopen", Opie::Core::OResource::SmallIcon),"",this,"BrowseButton"); |
22 | browserButton->setGeometry( QRect( 205, 10, 22, 22)); | 23 | browserButton->setGeometry( QRect( 205, 10, AppLnk::smallIconSize(), AppLnk::smallIconSize())); |
23 | connect( browserButton, SIGNAL(released()),this,SLOT(browse())); | 24 | connect( browserButton, SIGNAL(released()),this,SLOT(browse())); |
24 | LineEdit1 = new QLineEdit( this, "LineEdit1" ); | 25 | LineEdit1 = new QLineEdit( this, "LineEdit1" ); |
25 | LineEdit1->setGeometry( QRect( 4, 10, 190, 22 ) ); | 26 | LineEdit1->setGeometry( QRect( 4, 10, 190, 22 ) ); |
26 | LineEdit1->setFocus(); | 27 | LineEdit1->setFocus(); |
27 | } | 28 | } |
28 | /* | 29 | /* |
29 | * return the current text(input) | 30 | * return the current text(input) |
30 | */ | 31 | */ |
31 | QString InputDialog::text() const { | 32 | QString InputDialog::text() const { |
32 | return LineEdit1->text(); | 33 | return LineEdit1->text(); |
33 | } | 34 | } |
34 | /* | 35 | /* |
35 | * Destroys the object and frees any allocated resources | 36 | * Destroys the object and frees any allocated resources |
36 | */ | 37 | */ |
37 | InputDialog::~InputDialog() { | 38 | InputDialog::~InputDialog() { |
38 | } | 39 | } |
39 | 40 | ||
40 | void InputDialog::browse() { | 41 | void InputDialog::browse() { |
41 | 42 | ||
42 | MimeTypes types; | 43 | MimeTypes types; |
43 | QStringList audio, video, all; | 44 | QStringList audio, video, all; |
44 | audio << "audio/*"; | 45 | audio << "audio/*"; |
45 | audio << "playlist/plain"; | 46 | audio << "playlist/plain"; |
46 | audio << "audio/x-mpegurl"; | 47 | audio << "audio/x-mpegurl"; |