-rw-r--r-- | noncore/apps/opie-console/function_keyboard.cpp | 9 | ||||
-rw-r--r-- | noncore/apps/opie-console/function_keyboard.h | 5 | ||||
-rw-r--r-- | noncore/apps/opie-console/mainwindow.cpp | 42 |
3 files changed, 30 insertions, 26 deletions
diff --git a/noncore/apps/opie-console/function_keyboard.cpp b/noncore/apps/opie-console/function_keyboard.cpp index 0abe0d9..389618c 100644 --- a/noncore/apps/opie-console/function_keyboard.cpp +++ b/noncore/apps/opie-console/function_keyboard.cpp | |||
@@ -83,7 +83,7 @@ void FunctionKeyboard::load (const Profile& prof) { | |||
83 | // load pixmap if used | 83 | // load pixmap if used |
84 | if (!l[1].isEmpty()) { | 84 | if (!l[1].isEmpty()) { |
85 | 85 | ||
86 | keys[h].pix = new QPixmap( Resource::loadPixmap( "console/keys/" + l[1] ) ); | 86 | keys[h].pix = new QPixmap( Opie::Core::OResource::loadPixmap( "console/keys/" + l[1] ) ); |
87 | } | 87 | } |
88 | } | 88 | } |
89 | } | 89 | } |
@@ -277,8 +277,7 @@ FunctionKeyboardConfig::FunctionKeyboardConfig(const QString& name, QWidget* par | |||
277 | QStringList files = QDir( QPEApplication::qpeDir() + "pics/console/keys/", "*.png").entryList(); | 277 | QStringList files = QDir( QPEApplication::qpeDir() + "pics/console/keys/", "*.png").entryList(); |
278 | 278 | ||
279 | for (uint i = 0; i < files.count(); i++) { | 279 | for (uint i = 0; i < files.count(); i++) { |
280 | 280 | m_labels->insertItem( Opie::Core::OResource::loadPixmap("console/keys/" + files[i]), files[i]); | |
281 | m_labels->insertItem( Resource::loadPixmap("console/keys/" + files[i]), files[i]); | ||
282 | } | 281 | } |
283 | connect (m_labels, SIGNAL(activated(int)), this, SLOT(slotChangeIcon(int))); | 282 | connect (m_labels, SIGNAL(activated(int)), this, SLOT(slotChangeIcon(int))); |
284 | connect (m_labels, SIGNAL(textChanged(const QString&)), this, SLOT(slotChangeLabelText(const QString&))); | 283 | connect (m_labels, SIGNAL(textChanged(const QString&)), this, SLOT(slotChangeLabelText(const QString&))); |
@@ -328,7 +327,7 @@ void FunctionKeyboardConfig::load (const Profile& prof) { | |||
328 | // load pixmap if used | 327 | // load pixmap if used |
329 | if (!l[1].isEmpty()) { | 328 | if (!l[1].isEmpty()) { |
330 | 329 | ||
331 | kb->keys[h].pix = new QPixmap( Resource::loadPixmap( "console/keys/" + l[1] ) ); | 330 | kb->keys[h].pix = new QPixmap( Opie::Core::OResource::loadPixmap( "console/keys/" + l[1] ) ); |
332 | } | 331 | } |
333 | } | 332 | } |
334 | } | 333 | } |
@@ -403,7 +402,7 @@ void FunctionKeyboardConfig::slotChangeIcon(int index) { | |||
403 | // is a pixmap | 402 | // is a pixmap |
404 | m_labels->setEditable(false); | 403 | m_labels->setEditable(false); |
405 | kb->keys[selectedHandle].pixFile = m_labels->currentText(); | 404 | kb->keys[selectedHandle].pixFile = m_labels->currentText(); |
406 | kb->keys[selectedHandle].pix = new QPixmap( Resource::loadPixmap( "console/keys/" + m_labels->currentText() ) ); | 405 | kb->keys[selectedHandle].pix = new QPixmap( Opie::Core::OResource::loadPixmap( "console/keys/" + m_labels->currentText() ) ); |
407 | } | 406 | } |
408 | kb->paintKey(selectedRow, selectedCol); | 407 | kb->paintKey(selectedRow, selectedCol); |
409 | } | 408 | } |
diff --git a/noncore/apps/opie-console/function_keyboard.h b/noncore/apps/opie-console/function_keyboard.h index a60ff4b..b7e211c 100644 --- a/noncore/apps/opie-console/function_keyboard.h +++ b/noncore/apps/opie-console/function_keyboard.h | |||
@@ -1,8 +1,9 @@ | |||
1 | #ifndef OPIE_FUNCTION_KEYBOARD_H | 1 | #ifndef OPIE_FUNCTION_KEYBOARD_H |
2 | #define OPIE_FUNCTION_KEYBOARD_H | 2 | #define OPIE_FUNCTION_KEYBOARD_H |
3 | 3 | ||
4 | #include <opie2/oresource.h> | ||
5 | |||
4 | #include <qpe/config.h> | 6 | #include <qpe/config.h> |
5 | #include <qpe/resource.h> | ||
6 | #include <qpe/qpeapplication.h> | 7 | #include <qpe/qpeapplication.h> |
7 | #include <qframe.h> | 8 | #include <qframe.h> |
8 | #include <qpainter.h> | 9 | #include <qpainter.h> |
@@ -22,7 +23,7 @@ struct FKey { | |||
22 | 23 | ||
23 | if (!f.isEmpty()) { | 24 | if (!f.isEmpty()) { |
24 | 25 | ||
25 | pix = new QPixmap ( Resource::loadPixmap("console/keys/" + f ) ); | 26 | pix = new QPixmap ( Opie::Core::OResource::loadPixmap("console/keys/" + f ) ); |
26 | } | 27 | } |
27 | }; | 28 | }; |
28 | 29 | ||
diff --git a/noncore/apps/opie-console/mainwindow.cpp b/noncore/apps/opie-console/mainwindow.cpp index eaa78c8..45a662c 100644 --- a/noncore/apps/opie-console/mainwindow.cpp +++ b/noncore/apps/opie-console/mainwindow.cpp | |||
@@ -13,6 +13,7 @@ | |||
13 | 13 | ||
14 | /* OPIE */ | 14 | /* OPIE */ |
15 | #include <opie2/ofiledialog.h> | 15 | #include <opie2/ofiledialog.h> |
16 | #include <opie2/oresource.h> | ||
16 | #include <qpe/filemanager.h> | 17 | #include <qpe/filemanager.h> |
17 | using namespace Opie::Ui; | 18 | using namespace Opie::Ui; |
18 | 19 | ||
@@ -76,8 +77,8 @@ void MainWindow::initUI() { | |||
76 | * the settings action | 77 | * the settings action |
77 | */ | 78 | */ |
78 | m_setProfiles = new QAction(tr("Configure Profiles"), | 79 | m_setProfiles = new QAction(tr("Configure Profiles"), |
79 | Resource::loadPixmap( "SettingsIcon" ), | 80 | Opie::Core::OResource::loadPixmap( "SettingsIcon", Opie::Core::OResource::SmallIcon ), |
80 | QString::null, 0, this, 0); | 81 | QString::null, 0, this, 0); |
81 | m_setProfiles->addTo( m_console ); | 82 | m_setProfiles->addTo( m_console ); |
82 | connect( m_setProfiles, SIGNAL(activated() ), | 83 | connect( m_setProfiles, SIGNAL(activated() ), |
83 | this, SLOT(slotConfigure() ) ); | 84 | this, SLOT(slotConfigure() ) ); |
@@ -87,8 +88,8 @@ void MainWindow::initUI() { | |||
87 | * new Action for new sessions | 88 | * new Action for new sessions |
88 | */ | 89 | */ |
89 | QAction* newCon = new QAction(tr("New Profile"), | 90 | QAction* newCon = new QAction(tr("New Profile"), |
90 | Resource::loadPixmap( "new" ), | 91 | Opie::Core::OResource::loadPixmap( "new", Opie::Core::OResource::SmallIcon ), |
91 | QString::null, 0, this, 0); | 92 | QString::null, 0, this, 0); |
92 | newCon->addTo( m_console ); | 93 | newCon->addTo( m_console ); |
93 | connect( newCon, SIGNAL(activated() ), | 94 | connect( newCon, SIGNAL(activated() ), |
94 | this, SLOT(slotNew() ) ); | 95 | this, SLOT(slotNew() ) ); |
@@ -96,8 +97,8 @@ void MainWindow::initUI() { | |||
96 | m_console->insertSeparator(); | 97 | m_console->insertSeparator(); |
97 | 98 | ||
98 | QAction *saveCon = new QAction( tr("Save Profile" ), | 99 | QAction *saveCon = new QAction( tr("Save Profile" ), |
99 | Resource::loadPixmap( "save" ), QString::null, | 100 | Opie::Core::OResource::loadPixmap( "save", Opie::Core::OResource::SmallIcon ), QString::null, |
100 | 0, this, 0 ); | 101 | 0, this, 0 ); |
101 | saveCon->addTo( m_console ); | 102 | saveCon->addTo( m_console ); |
102 | connect( saveCon, SIGNAL(activated() ), | 103 | connect( saveCon, SIGNAL(activated() ), |
103 | this, SLOT(slotSaveSession() ) ); | 104 | this, SLOT(slotSaveSession() ) ); |
@@ -106,8 +107,8 @@ void MainWindow::initUI() { | |||
106 | /* | 107 | /* |
107 | * connect action | 108 | * connect action |
108 | */ | 109 | */ |
109 | m_connect = new QAction( tr("Connect"), Resource::loadPixmap("console/connected"), | 110 | m_connect = new QAction( tr("Connect"), Opie::Core::OResource::loadPixmap("console/connected", |
110 | QString::null, 0, this, 0 ); | 111 | Opie::Core::OResource::SmallIcon ), QString::null, 0, this, 0 ); |
111 | m_connect->addTo( m_console ); | 112 | m_connect->addTo( m_console ); |
112 | connect(m_connect, SIGNAL(activated() ), | 113 | connect(m_connect, SIGNAL(activated() ), |
113 | this, SLOT(slotConnect() ) ); | 114 | this, SLOT(slotConnect() ) ); |
@@ -115,8 +116,8 @@ void MainWindow::initUI() { | |||
115 | /* | 116 | /* |
116 | * disconnect action | 117 | * disconnect action |
117 | */ | 118 | */ |
118 | m_disconnect = new QAction( tr("Disconnect"), Resource::loadPixmap("console/notconnected"), | 119 | m_disconnect = new QAction( tr("Disconnect"), Opie::Core::OResource::loadPixmap("console/notconnected", |
119 | QString::null, 0, this, 0 ); | 120 | Opie::Core::OResource::SmallIcon ), QString::null, 0, this, 0 ); |
120 | m_disconnect->addTo( m_console ); | 121 | m_disconnect->addTo( m_console ); |
121 | connect(m_disconnect, SIGNAL(activated() ), | 122 | connect(m_disconnect, SIGNAL(activated() ), |
122 | this, SLOT(slotDisconnect() ) ); | 123 | this, SLOT(slotDisconnect() ) ); |
@@ -124,7 +125,9 @@ void MainWindow::initUI() { | |||
124 | m_console->insertSeparator(); | 125 | m_console->insertSeparator(); |
125 | 126 | ||
126 | #ifndef EAST | 127 | #ifndef EAST |
127 | m_quickLaunch = new QAction( tr("QuickLaunch"), Resource::loadPixmap("console/konsole_mini"), QString::null, 0, this, 0 ); | 128 | m_quickLaunch = new QAction( tr("QuickLaunch"), |
129 | Opie::Core::OResource::loadPixmap("console/konsole_mini", Opie::Core::OResource::SmallIcon ), | ||
130 | QString::null, 0, this, 0 ); | ||
128 | m_quickLaunch->addTo( m_icons ); | 131 | m_quickLaunch->addTo( m_icons ); |
129 | connect( m_quickLaunch, SIGNAL( activated() ), | 132 | connect( m_quickLaunch, SIGNAL( activated() ), |
130 | this, SLOT( slotQuickLaunch() ) ); | 133 | this, SLOT( slotQuickLaunch() ) ); |
@@ -132,8 +135,8 @@ void MainWindow::initUI() { | |||
132 | 135 | ||
133 | QWhatsThis::add( m_icons, tr( "The shell button launches the \"default\" profile. If there is none default values are taken" ) ); | 136 | QWhatsThis::add( m_icons, tr( "The shell button launches the \"default\" profile. If there is none default values are taken" ) ); |
134 | 137 | ||
135 | m_transfer = new QAction( tr("Transfer file..."), Resource::loadPixmap("pass") , QString::null, | 138 | m_transfer = new QAction( tr("Transfer file..."), Opie::Core::OResource::loadPixmap("pass", Opie::Core::OResource::SmallIcon ), |
136 | 0, this, 0 ); | 139 | QString::null, 0, this, 0 ); |
137 | m_transfer->addTo( m_console ); | 140 | m_transfer->addTo( m_console ); |
138 | connect(m_transfer, SIGNAL(activated() ), | 141 | connect(m_transfer, SIGNAL(activated() ), |
139 | this, SLOT(slotTransfer() ) ); | 142 | this, SLOT(slotTransfer() ) ); |
@@ -144,7 +147,8 @@ void MainWindow::initUI() { | |||
144 | * immediate change of line wrap policy | 147 | * immediate change of line wrap policy |
145 | */ | 148 | */ |
146 | m_isWrapped = true; | 149 | m_isWrapped = true; |
147 | m_wrap = new QAction( tr("Line wrap"), Resource::loadPixmap( "linewrap" ), QString::null, 0, this, 0, true ); | 150 | m_wrap = new QAction( tr("Line wrap"), Opie::Core::OResource::loadPixmap( "linewrap", Opie::Core::OResource::SmallIcon ), |
151 | QString::null, 0, this, 0, true ); | ||
148 | m_wrap->addTo( m_console ); | 152 | m_wrap->addTo( m_console ); |
149 | m_wrap->setOn( true ); | 153 | m_wrap->setOn( true ); |
150 | connect( m_wrap, SIGNAL( activated() ), SLOT( slotWrap() ) ); | 154 | connect( m_wrap, SIGNAL( activated() ), SLOT( slotWrap() ) ); |
@@ -154,8 +158,8 @@ void MainWindow::initUI() { | |||
154 | */ | 158 | */ |
155 | m_isFullscreen = false; | 159 | m_isFullscreen = false; |
156 | 160 | ||
157 | m_fullscreen = new QAction( tr("Full screen"), Resource::loadPixmap( "fullscreen" ) | 161 | m_fullscreen = new QAction( tr("Full screen"), Opie::Core::OResource::loadPixmap( "fullscreen", |
158 | , QString::null, 0, this, 0 ); | 162 | Opie::Core::OResource::SmallIcon ), QString::null, 0, this, 0 ); |
159 | m_fullscreen->addTo( m_console ); | 163 | m_fullscreen->addTo( m_console ); |
160 | connect( m_fullscreen, SIGNAL( activated() ), | 164 | connect( m_fullscreen, SIGNAL( activated() ), |
161 | this, SLOT( slotFullscreen() ) ); | 165 | this, SLOT( slotFullscreen() ) ); |
@@ -211,7 +215,7 @@ void MainWindow::initUI() { | |||
211 | * action that open/closes the keyboard | 215 | * action that open/closes the keyboard |
212 | */ | 216 | */ |
213 | m_openKeys = new QAction (tr("Open Keyboard..."), | 217 | m_openKeys = new QAction (tr("Open Keyboard..."), |
214 | Resource::loadPixmap( "console/keys/keyboard_icon" ), | 218 | Opie::Core::OResource::loadPixmap( "console/keys/keyboard_icon", Opie::Core::OResource::SmallIcon ), |
215 | QString::null, 0, this, 0); | 219 | QString::null, 0, this, 0); |
216 | m_openKeys->setToggleAction(true); | 220 | m_openKeys->setToggleAction(true); |
217 | connect (m_openKeys, SIGNAL(toggled(bool)), this, SLOT(slotOpenKeb(bool))); | 221 | connect (m_openKeys, SIGNAL(toggled(bool)), this, SLOT(slotOpenKeb(bool))); |
@@ -244,14 +248,14 @@ void MainWindow::initUI() { | |||
244 | 248 | ||
245 | 249 | ||
246 | a = new QAction(tr("Copy"), | 250 | a = new QAction(tr("Copy"), |
247 | Resource::loadPixmap("copy"), QString::null, | 251 | Opie::Core::OResource::loadPixmap("copy", Opie::Core::OResource::SmallIcon ), QString::null, |
248 | 0, this, 0 ); | 252 | 0, this, 0 ); |
249 | //a->addTo( m_icons ); | 253 | //a->addTo( m_icons ); |
250 | connect( a, SIGNAL(activated() ), | 254 | connect( a, SIGNAL(activated() ), |
251 | this, SLOT(slotCopy() ) ); | 255 | this, SLOT(slotCopy() ) ); |
252 | 256 | ||
253 | QAction *paste = new QAction(tr("Paste"), | 257 | QAction *paste = new QAction(tr("Paste"), |
254 | Resource::loadPixmap("paste"), QString::null, | 258 | Opie::Core::OResource::loadPixmap("paste", Opie::Core::OResource::SmallIcon ), QString::null, |
255 | 0, this, 0 ); | 259 | 0, this, 0 ); |
256 | connect( paste, SIGNAL(activated() ), | 260 | connect( paste, SIGNAL(activated() ), |
257 | this, SLOT(slotPaste() ) ); | 261 | this, SLOT(slotPaste() ) ); |