author | drw <drw> | 2005-05-16 17:37:44 (UTC) |
---|---|---|
committer | drw <drw> | 2005-05-16 17:37:44 (UTC) |
commit | a0276f0957bd503491e8d435b7ad1a6479ce24eb (patch) (side-by-side diff) | |
tree | 12be007f41dcbe7666b1a53578216cf12423596d | |
parent | e90364376c77a2f218b2fb291bb97eda7f18c3cb (diff) | |
download | opie-a0276f0957bd503491e8d435b7ad1a6479ce24eb.zip opie-a0276f0957bd503491e8d435b7ad1a6479ce24eb.tar.gz opie-a0276f0957bd503491e8d435b7ad1a6479ce24eb.tar.bz2 |
Resource -> OResource
-rw-r--r-- | noncore/apps/opie-write/mainwindow.cpp | 49 |
1 files changed, 27 insertions, 22 deletions
diff --git a/noncore/apps/opie-write/mainwindow.cpp b/noncore/apps/opie-write/mainwindow.cpp index aa03060..296a1b0 100644 --- a/noncore/apps/opie-write/mainwindow.cpp +++ b/noncore/apps/opie-write/mainwindow.cpp @@ -24,7 +24,7 @@ /* OPIE */ #include <opie2/odebug.h> +#include <opie2/oresource.h> #include <qpe/fileselector.h> #include <qpe/applnk.h> -#include <qpe/resource.h> #include <qpe/fontdatabase.h> using namespace Opie::Core; @@ -169,19 +169,21 @@ void MainWindow::setupActions() QAction *a; - a = new QAction( tr( "New" ), Resource::loadPixmap("new"), QString::null, 0, this, 0 ); + a = new QAction( tr( "New" ), Opie::Core::OResource::loadPixmap("new", Opie::Core::OResource::SmallIcon), + QString::null, 0, this, 0 ); connect( a, SIGNAL(activated()), this, SLOT(fileNew()) ); a->addTo( file ); - a = new QAction( tr( "Open" ), Resource::loadPixmap( "fileopen" ), QString::null, 0, this, 0 ); + a = new QAction( tr( "Open" ), Opie::Core::OResource::loadPixmap( "fileopen", Opie::Core::OResource::SmallIcon ), + QString::null, 0, this, 0 ); connect( a, SIGNAL(activated()), this, SLOT(fileOpen()) ); a->addTo( file ); - a = new QAction( tr( "Undo" ), Resource::loadIconSet("undo"), - QString::null, 0, this, "editUndo" ); + a = new QAction( tr( "Undo" ), Opie::Core::OResource::loadPixmap("undo", Opie::Core::OResource::SmallIcon), + QString::null, 0, this, "editUndo" ); connect( a, SIGNAL( activated() ), this, SLOT( editUndo() ) ); connect( editor, SIGNAL(undoAvailable(bool)), a, SLOT(setEnabled(bool)) ); a->addTo( tbEdit ); a->addTo( edit ); - a = new QAction( tr( "Redo" ), Resource::loadIconSet("redo"), + a = new QAction( tr( "Redo" ), Opie::Core::OResource::loadPixmap("redo", Opie::Core::OResource::SmallIcon), QString::null, 0, this, "editRedo" ); connect( a, SIGNAL( activated() ), this, SLOT( editRedo() ) ); @@ -192,5 +194,5 @@ void MainWindow::setupActions() edit->insertSeparator(); - a = new QAction( tr( "Copy" ), Resource::loadIconSet("copy"), + a = new QAction( tr( "Copy" ), Opie::Core::OResource::loadPixmap("copy", Opie::Core::OResource::SmallIcon ), QString::null, 0, this, "editCopy" ); connect( a, SIGNAL( activated() ), this, SLOT( editCopy() ) ); @@ -198,5 +200,5 @@ void MainWindow::setupActions() a->addTo( tbEdit ); a->addTo( edit ); - a = new QAction( tr( "Cut" ), Resource::loadIconSet("cut"), + a = new QAction( tr( "Cut" ), Opie::Core::OResource::loadPixmap("cut", Opie::Core::OResource::SmallIcon ), QString::null, 0, this, "editCut" ); connect( a, SIGNAL( activated() ), this, SLOT( editCut() ) ); @@ -204,5 +206,5 @@ void MainWindow::setupActions() a->addTo( tbEdit ); a->addTo( edit ); - a = new QAction( tr( "Paste" ), Resource::loadPixmap("paste"), + a = new QAction( tr( "Paste" ), Opie::Core::OResource::loadPixmap("paste", Opie::Core::OResource::SmallIcon ), QString::null, 0, this, "editPaste" ); connect( a, SIGNAL( activated() ), this, SLOT( editPaste() ) ); @@ -237,14 +239,14 @@ void MainWindow::setupActions() actionTextBold = new QAction( tr( "Bold" ), - Resource::loadPixmap("bold"), - QString::null, CTRL + Key_B, - this, "textBold" ); + Opie::Core::OResource::loadPixmap("bold", Opie::Core::OResource::SmallIcon ), + QString::null, CTRL + Key_B, + this, "textBold" ); connect( actionTextBold, SIGNAL( activated() ), this, SLOT( textBold() ) ); actionTextBold->addTo( tbStyle ); actionTextBold->setToggleAction( TRUE ); actionTextItalic = new QAction( tr( "Italic" ), - Resource::loadPixmap("italic"), - tr( "&Italic" ), CTRL + Key_I, - this, "textItalic" ); + Opie::Core::OResource::loadPixmap("italic", Opie::Core::OResource::SmallIcon ), + tr( "&Italic" ), CTRL + Key_I, + this, "textItalic" ); connect( actionTextItalic, SIGNAL( activated() ), this, SLOT( textItalic() ) ); @@ -252,7 +254,7 @@ void MainWindow::setupActions() actionTextItalic->setToggleAction( TRUE ); actionTextUnderline = new QAction( tr( "Underline" ), - Resource::loadPixmap("underline"), - tr( "&Underline" ), CTRL + Key_U, - this, "textUnderline" ); + Opie::Core::OResource::loadPixmap("underline", Opie::Core::OResource::SmallIcon ), + tr( "&Underline" ), CTRL + Key_U, + this, "textUnderline" ); connect( actionTextUnderline, SIGNAL( activated() ), this, SLOT( textUnderline() ) ); @@ -261,8 +263,11 @@ void MainWindow::setupActions() alignMenu = new ButtonMenu( tbStyle ); - alignMenu->insertItem( Resource::loadPixmap("left"), tr("Left"), AlignLeft ); - alignMenu->insertItem( Resource::loadPixmap("center"), tr("Center"), AlignCenter ); - alignMenu->insertItem( Resource::loadPixmap("right"), tr("Right"), AlignRight ); - alignMenu->insertItem( Resource::loadPixmap("opie-write/justify"), tr("Full"), Qt3::AlignJustify ); + alignMenu->insertItem( Opie::Core::OResource::loadPixmap("left", Opie::Core::OResource::SmallIcon), tr("Left"), AlignLeft ); + alignMenu->insertItem( Opie::Core::OResource::loadPixmap("center", Opie::Core::OResource::SmallIcon), + tr("Center"), AlignCenter ); + alignMenu->insertItem( Opie::Core::OResource::loadPixmap("right", Opie::Core::OResource::SmallIcon), + tr("Right"), AlignRight ); + alignMenu->insertItem( Opie::Core::OResource::loadPixmap("opie-write/justify", Opie::Core::OResource::SmallIcon), + tr("Full"), Qt3::AlignJustify ); connect( alignMenu, SIGNAL(activated(int)), this, SLOT(textAlign(int)) ); } |