summaryrefslogtreecommitdiffstats
path: root/src/bnpview.cpp
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2023-12-14 21:19:09 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2023-12-14 21:25:04 +0900
commit7b0920cd4180823f7a42350d1bdb914d697f4b9c (patch)
tree642d4c71c1e0b0a060be3119313c682943720363 /src/bnpview.cpp
parent1a620eed38cfa429508f6ac347e09a694b4adf16 (diff)
downloadbasket-7b0920cd4180823f7a42350d1bdb914d697f4b9c.tar.gz
basket-7b0920cd4180823f7a42350d1bdb914d697f4b9c.zip
Remove various '#define' strings - part 6
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'src/bnpview.cpp')
-rw-r--r--src/bnpview.cpp216
1 files changed, 108 insertions, 108 deletions
diff --git a/src/bnpview.cpp b/src/bnpview.cpp
index 6ee0647..8f9f83a 100644
--- a/src/bnpview.cpp
+++ b/src/bnpview.cpp
@@ -95,12 +95,12 @@ BNPView::BNPView(TQWidget *parent, const char *name, KXMLGUIClient *aGUIClient,
Global::bnpView = this;
// Needed when loading the baskets:
- Global::globalAccel = new TDEGlobalAccel(TQT_TQOBJECT(this)); // FIXME: might be null (KPart case)!
+ Global::globalAccel = new TDEGlobalAccel(this); // FIXME: might be null (KPart case)!
Global::backgroundManager = new BackgroundManager();
setupGlobalShortcuts();
initialize();
- TQTimer::singleShot(0, TQT_TQOBJECT(this), TQT_SLOT(lateInit()));
+ TQTimer::singleShot(0, this, TQT_SLOT(lateInit()));
}
BNPView::~BNPView()
@@ -188,8 +188,8 @@ void BNPView::lateInit()
m_tryHideTimer = new TQTimer(this);
m_hideTimer = new TQTimer(this);
- connect( m_tryHideTimer, TQT_SIGNAL(timeout()), TQT_TQOBJECT(this), TQT_SLOT(timeoutTryHide()) );
- connect( m_hideTimer, TQT_SIGNAL(timeout()), TQT_TQOBJECT(this), TQT_SLOT(timeoutHide()) );
+ connect( m_tryHideTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(timeoutTryHide()) );
+ connect( m_hideTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(timeoutHide()) );
// Preload every baskets for instant filtering:
/*StopWatch::start(100);
@@ -276,62 +276,62 @@ void BNPView::setupGlobalShortcuts()
globalAccel->insert( "global_show_hide_main_window", i18n("Show/hide main window"),
i18n("Allows you to show main Window if it is hidden, and to hide it if it is shown."),
TQt::CTRL + TQt::ALT + TQt::SHIFT + TQt::Key_W, TQt::CTRL + TQt::ALT + TQt::SHIFT + TQt::Key_W,
- TQT_TQOBJECT(basketMainWindow), TQT_SLOT(changeActive()), true, true );
+ basketMainWindow, TQT_SLOT(changeActive()), true, true );
}
globalAccel->insert( "global_paste", i18n("Paste clipboard contents in current basket"),
i18n("Allows you to paste clipboard contents in the current basket without having to open the main window."),
TQt::CTRL + TQt::ALT + TQt::SHIFT + TQt::Key_V, TQt::CTRL + TQt::ALT + TQt::SHIFT + TQt::Key_V,
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(globalPasteInCurrentBasket()), true, true );
+ Global::bnpView, TQT_SLOT(globalPasteInCurrentBasket()), true, true );
globalAccel->insert( "global_show_current_basket", i18n("Show current basket name"),
i18n("Allows you to know basket is current without opening the main window."),
"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(showPassiveContentForced()), true, true );
+ Global::bnpView, TQT_SLOT(showPassiveContentForced()), true, true );
globalAccel->insert( "global_paste_selection", i18n("Paste selection in current basket"),
i18n("Allows you to paste clipboard selection in the current basket without having to open the main window."),
TQt::CTRL + TQt::ALT + TQt::SHIFT + TQt::Key_S, TQt::CTRL + TQt::ALT + TQt::SHIFT + TQt::Key_S,
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(pasteSelInCurrentBasket()), true, true );
+ Global::bnpView, TQT_SLOT(pasteSelInCurrentBasket()), true, true );
globalAccel->insert( "global_new_basket", i18n("Create a new basket"),
i18n("Allows you to create a new basket without having to open the main window (you then can use the other global shortcuts to add a note, paste clipboard or paste selection in this new basket)."),
"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(askNewBasket()), true, true );
+ Global::bnpView, TQT_SLOT(askNewBasket()), true, true );
globalAccel->insert( "global_previous_basket", i18n("Go to previous basket"),
i18n("Allows you to change current basket to the previous one without having to open the main window."),
"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(goToPreviousBasket()), true, true );
+ Global::bnpView, TQT_SLOT(goToPreviousBasket()), true, true );
globalAccel->insert( "global_next_basket", i18n("Go to next basket"),
i18n("Allows you to change current basket to the next one without having to open the main window."),
"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(goToNextBasket()), true, true );
+ Global::bnpView, TQT_SLOT(goToNextBasket()), true, true );
// globalAccel->insert( "global_note_add_text", i18n("Insert plain text note"),
// i18n("Add a plain text note to the current basket without having to open the main window."),
// "", "", //TQt::CTRL+TQt::ALT+TQt::Key_T, TQt::CTRL+TQt::ALT+TQt::Key_T,
-// TQT_TQOBJECT(Global::bnpView), TQT_SLOT(addNoteText()), true, true );
+// Global::bnpView, TQT_SLOT(addNoteText()), true, true );
globalAccel->insert( "global_note_add_html", i18n("Insert text note"),
i18n("Add a text note to the current basket without having to open the main window."),
TQt::CTRL + TQt::ALT + TQt::SHIFT + TQt::Key_T, TQt::CTRL + TQt::ALT + TQt::SHIFT + TQt::Key_T, //"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(addNoteHtml()), true, true );
+ Global::bnpView, TQT_SLOT(addNoteHtml()), true, true );
globalAccel->insert( "global_note_add_image", i18n("Insert image note"),
i18n("Add an image note to the current basket without having to open the main window."),
"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(addNoteImage()), true, true );
+ Global::bnpView, TQT_SLOT(addNoteImage()), true, true );
globalAccel->insert( "global_note_add_link", i18n("Insert link note"),
i18n("Add a link note to the current basket without having to open the main window."),
"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(addNoteLink()), true, true );
+ Global::bnpView, TQT_SLOT(addNoteLink()), true, true );
globalAccel->insert( "global_note_add_color", i18n("Insert color note"),
i18n("Add a color note to the current basket without having to open the main window."),
"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(addNoteColor()), true, true );
+ Global::bnpView, TQT_SLOT(addNoteColor()), true, true );
globalAccel->insert( "global_note_pick_color", i18n("Pick color from screen"),
i18n("Add a color note picked from one pixel on screen to the current basket without "
"having to open the main window."),
"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(slotColorFromScreenGlobal()), true, true );
+ Global::bnpView, TQT_SLOT(slotColorFromScreenGlobal()), true, true );
globalAccel->insert( "global_note_grab_screenshot", i18n("Grab screen zone"),
i18n("Grab a screen zone as an image in the current basket without "
"having to open the main window."),
"", "",
- TQT_TQOBJECT(Global::bnpView), TQT_SLOT(grabScreenshotGlobal()), true, true );
+ Global::bnpView, TQT_SLOT(grabScreenshotGlobal()), true, true );
globalAccel->readSettings();
globalAccel->updateConnections();
}
@@ -369,21 +369,21 @@ void BNPView::initialize()
setResizeMode(m_stack, TQSplitter::Stretch);
/// Configure the List View Signals:
- connect( m_tree, TQT_SIGNAL(returnPressed(TQListViewItem*)), TQT_TQOBJECT(this), TQT_SLOT(slotPressed(TQListViewItem*)) );
- connect( m_tree, TQT_SIGNAL(selectionChanged(TQListViewItem*)), TQT_TQOBJECT(this), TQT_SLOT(slotPressed(TQListViewItem*)) );
- connect( m_tree, TQT_SIGNAL(pressed(TQListViewItem*)), TQT_TQOBJECT(this), TQT_SLOT(slotPressed(TQListViewItem*)) );
- connect( m_tree, TQT_SIGNAL(expanded(TQListViewItem*)), TQT_TQOBJECT(this), TQT_SLOT(needSave(TQListViewItem*)) );
- connect( m_tree, TQT_SIGNAL(collapsed(TQListViewItem*)), TQT_TQOBJECT(this), TQT_SLOT(needSave(TQListViewItem*)) );
- connect( m_tree, TQT_SIGNAL(contextMenu(TDEListView*, TQListViewItem*, const TQPoint&)), TQT_TQOBJECT(this), TQT_SLOT(slotContextMenu(TDEListView*, TQListViewItem*, const TQPoint&)) );
- connect( m_tree, TQT_SIGNAL(mouseButtonPressed(int, TQListViewItem*, const TQPoint&, int)), TQT_TQOBJECT(this), TQT_SLOT(slotMouseButtonPressed(int, TQListViewItem*, const TQPoint&, int)) );
- connect( m_tree, TQT_SIGNAL(doubleClicked(TQListViewItem*, const TQPoint&, int)), TQT_TQOBJECT(this), TQT_SLOT(slotShowProperties(TQListViewItem*, const TQPoint&, int)) );
+ connect( m_tree, TQT_SIGNAL(returnPressed(TQListViewItem*)), this, TQT_SLOT(slotPressed(TQListViewItem*)) );
+ connect( m_tree, TQT_SIGNAL(selectionChanged(TQListViewItem*)), this, TQT_SLOT(slotPressed(TQListViewItem*)) );
+ connect( m_tree, TQT_SIGNAL(pressed(TQListViewItem*)), this, TQT_SLOT(slotPressed(TQListViewItem*)) );
+ connect( m_tree, TQT_SIGNAL(expanded(TQListViewItem*)), this, TQT_SLOT(needSave(TQListViewItem*)) );
+ connect( m_tree, TQT_SIGNAL(collapsed(TQListViewItem*)), this, TQT_SLOT(needSave(TQListViewItem*)) );
+ connect( m_tree, TQT_SIGNAL(contextMenu(TDEListView*, TQListViewItem*, const TQPoint&)), this, TQT_SLOT(slotContextMenu(TDEListView*, TQListViewItem*, const TQPoint&)) );
+ connect( m_tree, TQT_SIGNAL(mouseButtonPressed(int, TQListViewItem*, const TQPoint&, int)), this, TQT_SLOT(slotMouseButtonPressed(int, TQListViewItem*, const TQPoint&, int)) );
+ connect( m_tree, TQT_SIGNAL(doubleClicked(TQListViewItem*, const TQPoint&, int)), this, TQT_SLOT(slotShowProperties(TQListViewItem*, const TQPoint&, int)) );
connect( m_tree, TQT_SIGNAL(expanded(TQListViewItem*)), this, TQT_SIGNAL(basketChanged()) );
connect( m_tree, TQT_SIGNAL(collapsed(TQListViewItem*)), this, TQT_SIGNAL(basketChanged()) );
connect( this, TQT_SIGNAL(basketNumberChanged(int)), this, TQT_SIGNAL(basketChanged()) );
- connect( this, TQT_SIGNAL(basketNumberChanged(int)), TQT_TQOBJECT(this), TQT_SLOT(slotBasketNumberChanged(int)) );
- connect( this, TQT_SIGNAL(basketChanged()), TQT_TQOBJECT(this), TQT_SLOT(slotBasketChanged()) );
+ connect( this, TQT_SIGNAL(basketNumberChanged(int)), this, TQT_SLOT(slotBasketNumberChanged(int)) );
+ connect( this, TQT_SIGNAL(basketChanged()), this, TQT_SLOT(slotBasketChanged()) );
/* LikeBack */
Global::likeBack = new LikeBack(LikeBack::AllButtons, /*showBarByDefault=*/false, Global::config(), Global::about());
@@ -412,91 +412,91 @@ void BNPView::initialize()
void BNPView::setupActions()
{
m_actSaveAsArchive = new TDEAction( i18n("&Basket Archive..."), "baskets", 0,
- TQT_TQOBJECT(this), TQT_SLOT(saveAsArchive()), actionCollection(), "basket_export_basket_archive" );
+ this, TQT_SLOT(saveAsArchive()), actionCollection(), "basket_export_basket_archive" );
m_actOpenArchive = new TDEAction( i18n("&Basket Archive..."), "baskets", 0,
- TQT_TQOBJECT(this), TQT_SLOT(openArchive()), actionCollection(), "basket_import_basket_archive" );
+ this, TQT_SLOT(openArchive()), actionCollection(), "basket_import_basket_archive" );
m_actHideWindow = new TDEAction( i18n("&Hide Window"), "", TDEStdAccel::shortcut(TDEStdAccel::Close),
- TQT_TQOBJECT(this), TQT_SLOT(hideOnEscape()), actionCollection(), "window_hide" );
+ this, TQT_SLOT(hideOnEscape()), actionCollection(), "window_hide" );
m_actHideWindow->setEnabled(Settings::useSystray()); // Init here !
m_actExportToHtml = new TDEAction( i18n("&HTML Web Page..."), "text-html", 0,
- TQT_TQOBJECT(this), TQT_SLOT(exportToHTML()), actionCollection(), "basket_export_html" );
+ this, TQT_SLOT(exportToHTML()), actionCollection(), "basket_export_html" );
new TDEAction( i18n("K&Notes"), "knotes", 0,
- TQT_TQOBJECT(this), TQT_SLOT(importKNotes()), actionCollection(), "basket_import_knotes" );
+ this, TQT_SLOT(importKNotes()), actionCollection(), "basket_import_knotes" );
new TDEAction( i18n("K&Jots"), "kjots", 0,
- TQT_TQOBJECT(this), TQT_SLOT(importKJots()), actionCollection(), "basket_import_kjots" );
+ this, TQT_SLOT(importKJots()), actionCollection(), "basket_import_kjots" );
new TDEAction( i18n("&KnowIt..."), "knowit", 0,
- TQT_TQOBJECT(this), TQT_SLOT(importKnowIt()), actionCollection(), "basket_import_knowit" );
+ this, TQT_SLOT(importKnowIt()), actionCollection(), "basket_import_knowit" );
new TDEAction( i18n("Tux&Cards..."), "tuxcards", 0,
- TQT_TQOBJECT(this), TQT_SLOT(importTuxCards()), actionCollection(), "basket_import_tuxcards" );
+ this, TQT_SLOT(importTuxCards()), actionCollection(), "basket_import_tuxcards" );
new TDEAction( i18n("&Sticky Notes"), "gnome", 0,
- TQT_TQOBJECT(this), TQT_SLOT(importStickyNotes()), actionCollection(), "basket_import_sticky_notes" );
+ this, TQT_SLOT(importStickyNotes()), actionCollection(), "basket_import_sticky_notes" );
new TDEAction( i18n("&Tomboy"), "tintin", 0,
- TQT_TQOBJECT(this), TQT_SLOT(importTomboy()), actionCollection(), "basket_import_tomboy" );
+ this, TQT_SLOT(importTomboy()), actionCollection(), "basket_import_tomboy" );
new TDEAction( i18n("Text &File..."), "text-plain", 0,
- TQT_TQOBJECT(this), TQT_SLOT(importTextFile()), actionCollection(), "basket_import_text_file" );
+ this, TQT_SLOT(importTextFile()), actionCollection(), "basket_import_text_file" );
new TDEAction( i18n("&Backup && Restore..."), "", 0,
- TQT_TQOBJECT(this), TQT_SLOT(backupRestore()), actionCollection(), "basket_backup_restore" );
+ this, TQT_SLOT(backupRestore()), actionCollection(), "basket_backup_restore" );
/** Note : ****************************************************************/
m_actDelNote = new TDEAction( i18n("D&elete"), "edit-delete", "Delete",
- TQT_TQOBJECT(this), TQT_SLOT(delNote()), actionCollection(), "edit_delete" );
- m_actCutNote = KStdAction::cut( TQT_TQOBJECT(this), TQT_SLOT(cutNote()), actionCollection() );
- m_actCopyNote = KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT(copyNote()), actionCollection() );
+ this, TQT_SLOT(delNote()), actionCollection(), "edit_delete" );
+ m_actCutNote = KStdAction::cut( this, TQT_SLOT(cutNote()), actionCollection() );
+ m_actCopyNote = KStdAction::copy( this, TQT_SLOT(copyNote()), actionCollection() );
- m_actSelectAll = KStdAction::selectAll( TQT_TQOBJECT(this), TQT_SLOT( slotSelectAll() ), actionCollection() );
+ m_actSelectAll = KStdAction::selectAll( this, TQT_SLOT( slotSelectAll() ), actionCollection() );
m_actSelectAll->setStatusText( i18n( "Selects all notes" ) );
- m_actUnselectAll = new TDEAction( i18n( "U&nselect All" ), "", TQT_TQOBJECT(this), TQT_SLOT( slotUnselectAll() ),
+ m_actUnselectAll = new TDEAction( i18n( "U&nselect All" ), "", this, TQT_SLOT( slotUnselectAll() ),
actionCollection(), "edit_unselect_all" );
m_actUnselectAll->setStatusText( i18n( "Unselects all selected notes" ) );
m_actInvertSelection = new TDEAction( i18n( "&Invert Selection" ), CTRL+Key_Asterisk,
- TQT_TQOBJECT(this), TQT_SLOT( slotInvertSelection() ),
+ this, TQT_SLOT( slotInvertSelection() ),
actionCollection(), "edit_invert_selection" );
m_actInvertSelection->setStatusText( i18n( "Inverts the current selection of notes" ) );
m_actEditNote = new TDEAction( i18n("Verb; not Menu", "&Edit..."), "edit", "Return",
- TQT_TQOBJECT(this), TQT_SLOT(editNote()), actionCollection(), "note_edit" );
+ this, TQT_SLOT(editNote()), actionCollection(), "note_edit" );
- m_actOpenNote = KStdAction::open( TQT_TQOBJECT(this), TQT_SLOT(openNote()), actionCollection(), "note_open" );
+ m_actOpenNote = KStdAction::open( this, TQT_SLOT(openNote()), actionCollection(), "note_open" );
m_actOpenNote->setIcon("window-new");
m_actOpenNote->setText(i18n("&Open"));
m_actOpenNote->setShortcut("F9");
m_actOpenNoteWith = new TDEAction( i18n("Open &With..."), "", "Shift+F9",
- TQT_TQOBJECT(this), TQT_SLOT(openNoteWith()), actionCollection(), "note_open_with" );
- m_actSaveNoteAs = KStdAction::saveAs( TQT_TQOBJECT(this), TQT_SLOT(saveNoteAs()), actionCollection(), "note_save_to_file" );
+ this, TQT_SLOT(openNoteWith()), actionCollection(), "note_open_with" );
+ m_actSaveNoteAs = KStdAction::saveAs( this, TQT_SLOT(saveNoteAs()), actionCollection(), "note_save_to_file" );
m_actSaveNoteAs->setIcon("");
m_actSaveNoteAs->setText(i18n("&Save to File..."));
m_actSaveNoteAs->setShortcut("F10");
m_actGroup = new TDEAction( i18n("&Group"), "attach", "Ctrl+G",
- TQT_TQOBJECT(this), TQT_SLOT(noteGroup()), actionCollection(), "note_group" );
+ this, TQT_SLOT(noteGroup()), actionCollection(), "note_group" );
m_actUngroup = new TDEAction( i18n("U&ngroup"), "", "Ctrl+Shift+G",
- TQT_TQOBJECT(this), TQT_SLOT(noteUngroup()), actionCollection(), "note_ungroup" );
+ this, TQT_SLOT(noteUngroup()), actionCollection(), "note_ungroup" );
m_actMoveOnTop = new TDEAction( i18n("Move on &Top"), "2uparrow", "Ctrl+Shift+Home",
- TQT_TQOBJECT(this), TQT_SLOT(moveOnTop()), actionCollection(), "note_move_top" );
+ this, TQT_SLOT(moveOnTop()), actionCollection(), "note_move_top" );
m_actMoveNoteUp = new TDEAction( i18n("Move &Up"), "1uparrow", "Ctrl+Shift+Up",
- TQT_TQOBJECT(this), TQT_SLOT(moveNoteUp()), actionCollection(), "note_move_up" );
+ this, TQT_SLOT(moveNoteUp()), actionCollection(), "note_move_up" );
m_actMoveNoteDown = new TDEAction( i18n("Move &Down"), "1downarrow", "Ctrl+Shift+Down",
- TQT_TQOBJECT(this), TQT_SLOT(moveNoteDown()), actionCollection(), "note_move_down" );
+ this, TQT_SLOT(moveNoteDown()), actionCollection(), "note_move_down" );
m_actMoveOnBottom = new TDEAction( i18n("Move on &Bottom"), "2downarrow", "Ctrl+Shift+End",
- TQT_TQOBJECT(this), TQT_SLOT(moveOnBottom()), actionCollection(), "note_move_bottom" );
+ this, TQT_SLOT(moveOnBottom()), actionCollection(), "note_move_bottom" );
#if KDE_IS_VERSION( 3, 1, 90 ) // KDE 3.2.x
- m_actPaste = KStdAction::pasteText( TQT_TQOBJECT(this), TQT_SLOT(pasteInCurrentBasket()), actionCollection() );
+ m_actPaste = KStdAction::pasteText( this, TQT_SLOT(pasteInCurrentBasket()), actionCollection() );
#else
- m_actPaste = KStdAction::paste( TQT_TQOBJECT(this), TQT_SLOT(pasteInCurrentBasket()), actionCollection() );
+ m_actPaste = KStdAction::paste( this, TQT_SLOT(pasteInCurrentBasket()), actionCollection() );
#endif
/** Insert : **************************************************************/
- TQSignalMapper *insertEmptyMapper = new TQSignalMapper(TQT_TQOBJECT(this));
- TQSignalMapper *insertWizardMapper = new TQSignalMapper(TQT_TQOBJECT(this));
- connect( insertEmptyMapper, TQT_SIGNAL(mapped(int)), TQT_TQOBJECT(this), TQT_SLOT(insertEmpty(int)) );
- connect( insertWizardMapper, TQT_SIGNAL(mapped(int)), TQT_TQOBJECT(this), TQT_SLOT(insertWizard(int)) );
+ TQSignalMapper *insertEmptyMapper = new TQSignalMapper(this);
+ TQSignalMapper *insertWizardMapper = new TQSignalMapper(this);
+ connect( insertEmptyMapper, TQT_SIGNAL(mapped(int)), this, TQT_SLOT(insertEmpty(int)) );
+ connect( insertWizardMapper, TQT_SIGNAL(mapped(int)), this, TQT_SLOT(insertWizard(int)) );
// m_actInsertText = new TDEAction( i18n("Plai&n Text"), "text", "Ctrl+T", actionCollection(), "insert_text" );
m_actInsertHtml = new TDEAction( i18n("&Text"), "text-html", "Insert", actionCollection(), "insert_html" );
@@ -531,14 +531,14 @@ void BNPView::setupActions()
m_colorPicker = new DesktopColorPicker();
m_actColorPicker = new TDEAction( i18n("C&olor from Screen"), "kcolorchooser", "",
- TQT_TQOBJECT(this), TQT_SLOT(slotColorFromScreen()), actionCollection(), "insert_screen_color" );
- connect( m_colorPicker, TQT_SIGNAL(pickedColor(const TQColor&)), TQT_TQOBJECT(this), TQT_SLOT(colorPicked(const TQColor&)) );
- connect( m_colorPicker, TQT_SIGNAL(canceledPick()), TQT_TQOBJECT(this), TQT_SLOT(colorPickingCanceled()) );
+ this, TQT_SLOT(slotColorFromScreen()), actionCollection(), "insert_screen_color" );
+ connect( m_colorPicker, TQT_SIGNAL(pickedColor(const TQColor&)), this, TQT_SLOT(colorPicked(const TQColor&)) );
+ connect( m_colorPicker, TQT_SIGNAL(canceledPick()), this, TQT_SLOT(colorPickingCanceled()) );
m_actGrabScreenshot = new TDEAction( i18n("Grab Screen &Zone"), "ksnapshot", "",
- TQT_TQOBJECT(this), TQT_SLOT(grabScreenshot()), actionCollection(), "insert_screen_capture" );
- //connect( m_actGrabScreenshot, TQT_SIGNAL(regionGrabbed(const TQPixmap&)), TQT_TQOBJECT(this), TQT_SLOT(screenshotGrabbed(const TQPixmap&)) );
- //connect( m_colorPicker, TQT_SIGNAL(canceledPick()), TQT_TQOBJECT(this), TQT_SLOT(colorPickingCanceled()) );
+ this, TQT_SLOT(grabScreenshot()), actionCollection(), "insert_screen_capture" );
+ //connect( m_actGrabScreenshot, TQT_SIGNAL(regionGrabbed(const TQPixmap&)), this, TQT_SLOT(screenshotGrabbed(const TQPixmap&)) );
+ //connect( m_colorPicker, TQT_SIGNAL(canceledPick()), this, TQT_SLOT(colorPickingCanceled()) );
// m_insertActions.append( m_actInsertText );
m_insertActions.append( m_actInsertHtml );
@@ -566,69 +566,69 @@ void BNPView::setupActions()
// Use the "basket" incon in Kontact so it is consistent with the Kontact "New..." icon
actNewBasket = new TDEAction( i18n("&New Basket..."), (runInsideKontact ? "basket" : "document-new"), TDEStdAccel::shortcut(TDEStdAccel::New),
- TQT_TQOBJECT(this), TQT_SLOT(askNewBasket()), actionCollection(), "basket_new" );
+ this, TQT_SLOT(askNewBasket()), actionCollection(), "basket_new" );
actNewSubBasket = new TDEAction( i18n("New &Sub-Basket..."), "", "Ctrl+Shift+N",
- TQT_TQOBJECT(this), TQT_SLOT(askNewSubBasket()), actionCollection(), "basket_new_sub" );
+ this, TQT_SLOT(askNewSubBasket()), actionCollection(), "basket_new_sub" );
actNewSiblingBasket = new TDEAction( i18n("New Si&bling Basket..."), "", "",
- TQT_TQOBJECT(this), TQT_SLOT(askNewSiblingBasket()), actionCollection(), "basket_new_sibling" );
+ this, TQT_SLOT(askNewSiblingBasket()), actionCollection(), "basket_new_sibling" );
TDEActionMenu *newBasketMenu = new TDEActionMenu(i18n("&New"), "document-new", actionCollection(), "basket_new_menu");
newBasketMenu->insert(actNewBasket);
newBasketMenu->insert(actNewSubBasket);
newBasketMenu->insert(actNewSiblingBasket);
- connect( newBasketMenu, TQT_SIGNAL(activated()), TQT_TQOBJECT(this), TQT_SLOT(askNewBasket()) );
+ connect( newBasketMenu, TQT_SIGNAL(activated()), this, TQT_SLOT(askNewBasket()) );
m_actPropBasket = new TDEAction( i18n("&Properties..."), "misc", "F2",
- TQT_TQOBJECT(this), TQT_SLOT(propBasket()), actionCollection(), "basket_properties" );
+ this, TQT_SLOT(propBasket()), actionCollection(), "basket_properties" );
m_actDelBasket = new TDEAction( i18n("Remove Basket", "&Remove"), "", 0,
- TQT_TQOBJECT(this), TQT_SLOT(delBasket()), actionCollection(), "basket_remove" );
+ this, TQT_SLOT(delBasket()), actionCollection(), "basket_remove" );
#ifdef HAVE_LIBGPGME
m_actPassBasket = new TDEAction( i18n("Password protection", "Pass&word..."), "", 0,
- TQT_TQOBJECT(this), TQT_SLOT(password()), actionCollection(), "basket_password" );
+ this, TQT_SLOT(password()), actionCollection(), "basket_password" );
m_actLockBasket = new TDEAction( i18n("Lock Basket", "&Lock"), "", "Ctrl+L",
- TQT_TQOBJECT(this), TQT_SLOT(lockBasket()), actionCollection(), "basket_lock" );
+ this, TQT_SLOT(lockBasket()), actionCollection(), "basket_lock" );
#endif
/** Edit : ****************************************************************/
- //m_actUndo = KStdAction::undo( TQT_TQOBJECT(this), TQT_SLOT(undo()), actionCollection() );
+ //m_actUndo = KStdAction::undo( this, TQT_SLOT(undo()), actionCollection() );
//m_actUndo->setEnabled(false); // Not yet implemented !
- //m_actRedo = KStdAction::redo( TQT_TQOBJECT(this), TQT_SLOT(redo()), actionCollection() );
+ //m_actRedo = KStdAction::redo( this, TQT_SLOT(redo()), actionCollection() );
//m_actRedo->setEnabled(false); // Not yet implemented !
m_actShowFilter = new TDEToggleAction( i18n("&Filter"), "filter", TDEStdAccel::shortcut(TDEStdAccel::Find),
actionCollection(), "edit_filter" );
- connect( m_actShowFilter, TQT_SIGNAL(toggled(bool)), TQT_TQOBJECT(this), TQT_SLOT(showHideFilterBar(bool)) );
+ connect( m_actShowFilter, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(showHideFilterBar(bool)) );
m_actFilterAllBaskets = new TDEToggleAction( i18n("Filter all &Baskets"), "edit-find", "Ctrl+Shift+F",
actionCollection(), "edit_filter_all_baskets" );
- connect( m_actFilterAllBaskets, TQT_SIGNAL(toggled(bool)), TQT_TQOBJECT(this), TQT_SLOT(toggleFilterAllBaskets(bool)) );
+ connect( m_actFilterAllBaskets, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(toggleFilterAllBaskets(bool)) );
m_actResetFilter = new TDEAction( i18n( "&Reset Filter" ), "locationbar_erase", "Ctrl+R",
- TQT_TQOBJECT(this), TQT_SLOT( slotResetFilter() ), actionCollection(), "edit_filter_reset" );
+ this, TQT_SLOT( slotResetFilter() ), actionCollection(), "edit_filter_reset" );
/** Go : ******************************************************************/
m_actPreviousBasket = new TDEAction( i18n( "&Previous Basket" ), "go-up", "Alt+Up",
- TQT_TQOBJECT(this), TQT_SLOT(goToPreviousBasket()), actionCollection(), "go_basket_previous" );
+ this, TQT_SLOT(goToPreviousBasket()), actionCollection(), "go_basket_previous" );
m_actNextBasket = new TDEAction( i18n( "&Next Basket" ), "go-down", "Alt+Down",
- TQT_TQOBJECT(this), TQT_SLOT(goToNextBasket()), actionCollection(), "go_basket_next" );
+ this, TQT_SLOT(goToNextBasket()), actionCollection(), "go_basket_next" );
m_actFoldBasket = new TDEAction( i18n( "&Fold Basket" ), "back", "Alt+Left",
- TQT_TQOBJECT(this), TQT_SLOT(foldBasket()), actionCollection(), "go_basket_fold" );
+ this, TQT_SLOT(foldBasket()), actionCollection(), "go_basket_fold" );
m_actExpandBasket = new TDEAction( i18n( "&Expand Basket" ), "forward", "Alt+Right",
- TQT_TQOBJECT(this), TQT_SLOT(expandBasket()), actionCollection(), "go_basket_expand" );
+ this, TQT_SLOT(expandBasket()), actionCollection(), "go_basket_expand" );
// FOR_BETA_PURPOSE:
// m_convertTexts = new TDEAction( i18n("Convert text notes to rich text notes"), "compfile", "",
-// TQT_TQOBJECT(this), TQT_SLOT(convertTexts()), actionCollection(), "beta_convert_texts" );
+// this, TQT_SLOT(convertTexts()), actionCollection(), "beta_convert_texts" );
InlineEditors::instance()->initToolBars(actionCollection());
- actConfigGlobalShortcuts = KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(showGlobalShortcutsSettingsDialog()),
+ actConfigGlobalShortcuts = KStdAction::keyBindings(this, TQT_SLOT(showGlobalShortcutsSettingsDialog()),
actionCollection(), "options_configure_global_keybinding");
actConfigGlobalShortcuts->setText(i18n("Configure &Global Shortcuts..."));
/** Help : ****************************************************************/
- new TDEAction( i18n("&Welcome Baskets"), "", "", TQT_TQOBJECT(this), TQT_SLOT(addWelcomeBaskets()), actionCollection(), "help_welcome_baskets" );
+ new TDEAction( i18n("&Welcome Baskets"), "", "", this, TQT_SLOT(addWelcomeBaskets()), actionCollection(), "help_welcome_baskets" );
}
TQListViewItem* BNPView::firstListViewItem()
@@ -670,7 +670,7 @@ void BNPView::slotContextMenu(TDEListView */*listView*/, TQListViewItem *item, c
}
TQPopupMenu *menu = popupMenu(menuName);
- connect( menu, TQT_SIGNAL(aboutToHide()), TQT_TQOBJECT(this), TQT_SLOT(aboutToHideNewBasketPopup()) );
+ connect( menu, TQT_SIGNAL(aboutToHide()), this, TQT_SLOT(aboutToHideNewBasketPopup()) );
menu->exec(pos);
}
@@ -796,11 +796,11 @@ Basket* BNPView::loadBasket(const TQString &folderName)
DecoratedBasket *decoBasket = new DecoratedBasket(m_stack, folderName);
Basket *basket = decoBasket->basket();
m_stack->addWidget(decoBasket);
- connect( basket, TQT_SIGNAL(countsChanged(Basket*)), TQT_TQOBJECT(this), TQT_SLOT(countsChanged(Basket*)) );
+ connect( basket, TQT_SIGNAL(countsChanged(Basket*)), this, TQT_SLOT(countsChanged(Basket*)) );
// Important: Create listViewItem and connect signal BEFORE loadProperties(), so we get the listViewItem updated without extra work:
- connect( basket, TQT_SIGNAL(propertiesChanged(Basket*)), TQT_TQOBJECT(this), TQT_SLOT(updateBasketListViewItem(Basket*)) );
+ connect( basket, TQT_SIGNAL(propertiesChanged(Basket*)), this, TQT_SLOT(updateBasketListViewItem(Basket*)) );
- connect( basket->decoration()->filterBar(), TQT_SIGNAL(newFilter(const FilterData&)), TQT_TQOBJECT(this), TQT_SLOT(newFilterFromFilterBar()) );
+ connect( basket->decoration()->filterBar(), TQT_SIGNAL(newFilter(const FilterData&)), this, TQT_SLOT(newFilterFromFilterBar()) );
return basket;
}
@@ -1078,7 +1078,7 @@ void BNPView::newFilter()
void BNPView::newFilterFromFilterBar()
{
if (isFilteringAllBaskets())
- TQTimer::singleShot(0, TQT_TQOBJECT(this), TQT_SLOT(newFilter())); // Keep time for the TQLineEdit to display the filtered character and refresh correctly!
+ TQTimer::singleShot(0, this, TQT_SLOT(newFilter())); // Keep time for the TQLineEdit to display the filtered character and refresh correctly!
}
bool BNPView::isFilteringAllBaskets()
@@ -1243,7 +1243,7 @@ void BNPView::filterPlacementChanged(bool onTop)
TQListViewItemIterator it(m_tree);
while (it.current()) {
BasketListViewItem *item = static_cast<BasketListViewItem*>(it.current());
- DecoratedBasket *decoration = static_cast<DecoratedBasket*>(TQT_TQWIDGET(item->basket()->parent()));
+ DecoratedBasket *decoration = static_cast<DecoratedBasket*>(item->basket()->parent());
decoration->setFilterBarPosition(onTop);
++it;
}
@@ -1270,7 +1270,7 @@ void BNPView::needSave(TQListViewItem*)
{
if (!m_loading)
// A basket has been collapsed/expanded or a new one is select: this is not urgent:
- TQTimer::singleShot(500/*ms*/, TQT_TQOBJECT(this), TQT_SLOT(save()));
+ TQTimer::singleShot(500/*ms*/, this, TQT_SLOT(save()));
}
void BNPView::slotPressed(TQListViewItem *item, const TQPoint &/*pos*/, int /*column*/)
@@ -1431,7 +1431,7 @@ void BNPView::updateNotesActions()
}
} else if (m_type != Color) {
popupMenu->insertSeparator();
- popupMenu->insertItem( SmallIconSet("document-save-as"), i18n("&Save a copy as..."), TQT_TQOBJECT(this), TQT_SLOT(slotSaveAs()), 0, 10 );
+ popupMenu->insertItem( SmallIconSet("document-save-as"), i18n("&Save a copy as..."), this, TQT_SLOT(slotSaveAs()), 0, 10 );
}*/
}
@@ -1453,7 +1453,7 @@ void BNPView::slotColorFromScreen(bool global)
/* m_gettingColorFromScreen = true;
kapp->processEvents();
- TQTimer::singleShot( 100, TQT_TQOBJECT(this), TQT_SLOT(grabColorFromScreen()) );*/
+ TQTimer::singleShot( 100, this, TQT_SLOT(grabColorFromScreen()) );*/
}
void BNPView::slotColorFromScreenGlobal()
@@ -1612,7 +1612,7 @@ void BNPView::grabScreenshot(bool global)
currentBasket()->saveInsertionData();
m_regionGrabber = new RegionGrabber(delay);
- connect( m_regionGrabber, TQT_SIGNAL(regionGrabbed(const TQPixmap&)), TQT_TQOBJECT(this), TQT_SLOT(screenshotGrabbed(const TQPixmap&)) );
+ connect( m_regionGrabber, TQT_SIGNAL(regionGrabbed(const TQPixmap&)), this, TQT_SLOT(screenshotGrabbed(const TQPixmap&)) );
}
void BNPView::grabScreenshotGlobal()
@@ -1767,7 +1767,7 @@ void BNPView::doBasketDeletion(Basket *basket)
void BNPView::password()
{
#ifdef HAVE_LIBGPGME
- PasswordDlg dlg(TQT_TQWIDGET(kapp->activeWindow()), "Password");
+ PasswordDlg dlg(kapp->activeWindow(), "Password");
Basket *cur = currentBasket();
dlg.setType(cur->encryptionType());
@@ -1939,7 +1939,7 @@ void BNPView::showPassiveDropped(const TQString &title)
// TODO: Keep basket, so that we show the message only if something was added to a NOT visible basket
m_passiveDroppedTitle = title;
m_passiveDroppedSelection = currentBasket()->selectedNotes();
- TQTimer::singleShot( c_delayTooltipTime, TQT_TQOBJECT(this), TQT_SLOT(showPassiveDroppedDelayed()) );
+ TQTimer::singleShot( c_delayTooltipTime, this, TQT_SLOT(showPassiveDroppedDelayed()) );
// DELAY IT BELOW:
} else
showPassiveImpossible(i18n("No note was added."));
@@ -2023,7 +2023,7 @@ void BNPView::addNoteColor() { showMainWindow(); currentBasket()->insertEmptyNot
void BNPView::aboutToHideNewBasketPopup()
{
- TQTimer::singleShot(0, TQT_TQOBJECT(this), TQT_SLOT(cancelNewBasketPopup()));
+ TQTimer::singleShot(0, this, TQT_SLOT(cancelNewBasketPopup()));
}
void BNPView::cancelNewBasketPopup()
@@ -2277,7 +2277,7 @@ void BNPView::populateTagsMenu()
populateTagsMenu(*menu, referenceNote);
m_lastOpenedTagsMenu = menu;
-// connect( menu, TQT_SIGNAL(aboutToHide()), TQT_TQOBJECT(this), TQT_SLOT(disconnectTagsMenu()) );
+// connect( menu, TQT_SIGNAL(aboutToHide()), this, TQT_SLOT(disconnectTagsMenu()) );
}
void BNPView::populateTagsMenu(TDEPopupMenu &menu, Note *referenceNote)
@@ -2332,8 +2332,8 @@ void BNPView::populateTagsMenu(TDEPopupMenu &menu, Note *referenceNote)
void BNPView::connectTagsMenu()
{
- connect( popupMenu("tags"), TQT_SIGNAL(aboutToShow()), TQT_TQOBJECT(this), TQT_SLOT(populateTagsMenu()) );
- connect( popupMenu("tags"), TQT_SIGNAL(aboutToHide()), TQT_TQOBJECT(this), TQT_SLOT(disconnectTagsMenu()) );
+ connect( popupMenu("tags"), TQT_SIGNAL(aboutToShow()), this, TQT_SLOT(populateTagsMenu()) );
+ connect( popupMenu("tags"), TQT_SIGNAL(aboutToHide()), this, TQT_SLOT(disconnectTagsMenu()) );
}
/*
@@ -2348,7 +2348,7 @@ void BNPView::connectTagsMenu()
void BNPView::showEvent(TQShowEvent*)
{
if (isPart())
- TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT(connectTagsMenu()) );
+ TQTimer::singleShot( 0, this, TQT_SLOT(connectTagsMenu()) );
if (m_firstShow) {
m_firstShow = false;
@@ -2362,8 +2362,8 @@ void BNPView::showEvent(TQShowEvent*)
void BNPView::hideEvent(TQHideEvent*)
{
if (isPart()) {
- disconnect( popupMenu("tags"), TQT_SIGNAL(aboutToShow()), TQT_TQOBJECT(this), TQT_SLOT(populateTagsMenu()) );
- disconnect( popupMenu("tags"), TQT_SIGNAL(aboutToHide()), TQT_TQOBJECT(this), TQT_SLOT(disconnectTagsMenu()) );
+ disconnect( popupMenu("tags"), TQT_SIGNAL(aboutToShow()), this, TQT_SLOT(populateTagsMenu()) );
+ disconnect( popupMenu("tags"), TQT_SIGNAL(aboutToHide()), this, TQT_SLOT(disconnectTagsMenu()) );
}
if (isPart())
@@ -2372,7 +2372,7 @@ void BNPView::hideEvent(TQHideEvent*)
void BNPView::disconnectTagsMenu()
{
- TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT(disconnectTagsMenuDelayed()) );
+ TQTimer::singleShot( 0, this, TQT_SLOT(disconnectTagsMenuDelayed()) );
}
void BNPView::disconnectTagsMenuDelayed()