Silence warnings due to some deprecated.

Signed-off-by: gregory guy <gregory-tde@laposte.net>
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
gregory guy 3 years ago
parent b2a11325b0
commit 82b737fb73
No known key found for this signature in database
GPG Key ID: 2CC84A1CC6823AF8

@ -133,13 +133,7 @@ void KMouthApp::initActions() {
// The "Options" menu
viewMenuBar = KStdAction::showMenubar(TQT_TQOBJECT(this), TQT_SLOT(slotViewMenuBar()), actionCollection());
viewToolBar = KStdAction::showToolbar(TQT_TQOBJECT(this), TQT_SLOT(slotViewToolBar()), actionCollection());
viewToolBar->setStatusText(i18n("Enables/disables the toolbar"));
viewToolBar->setWhatsThis (i18n("Enables/disables the toolbar"));
viewPhrasebookBar = new TDEToggleAction (i18n("Show P&hrasebook Bar"), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(slotViewPhrasebookBar()), actionCollection(), "showPhrasebookBar");
viewPhrasebookBar->setStatusText(i18n("Enables/disables the phrasebook bar"));
viewPhrasebookBar->setWhatsThis (i18n("Enables/disables the phrasebook bar"));
setStandardToolBarMenuEnabled(true);
viewStatusBar = KStdAction::showStatusbar(TQT_TQOBJECT(this), TQT_SLOT(slotViewStatusBar()), actionCollection());
viewStatusBar->setStatusText(i18n("Enables/disables the statusbar"));
@ -215,8 +209,6 @@ void KMouthApp::saveOptions() {
config->setGroup("General Options");
config->writeEntry("Geometry", size());
config->writeEntry("Show Menubar", viewMenuBar->isChecked());
config->writeEntry("Show Toolbar", viewToolBar->isChecked());
config->writeEntry("Show Phrasebook Bar", viewPhrasebookBar->isChecked());
config->writeEntry("Show Statusbar",viewStatusBar->isChecked());
config->writeEntry("ToolBarPos", (int) toolBar("mainToolBar")->barPos());
@ -238,13 +230,6 @@ void KMouthApp::readOptions()
viewMenuBar->setChecked(bViewMenubar);
slotViewMenuBar();
bool bViewToolbar = config->readBoolEntry("Show Toolbar", true);
viewToolBar->setChecked(bViewToolbar);
slotViewToolBar();
bool bViewPhrasebookbar = config->readBoolEntry("Show Phrasebook Bar", true);
viewPhrasebookBar->setChecked(bViewPhrasebookbar);
bool bViewStatusbar = config->readBoolEntry("Show Statusbar", true);
viewStatusBar->setChecked(bViewStatusbar);
slotViewStatusBar();
@ -380,40 +365,6 @@ void KMouthApp::slotViewMenuBar() {
slotStatusMsg(i18n("Ready."));
}
void KMouthApp::slotViewToolBar()
{
slotStatusMsg(i18n("Toggling toolbar..."));
///////////////////////////////////////////////////////////////////
// turn Toolbar on or off
if(!viewToolBar->isChecked())
{
toolBar("mainToolBar")->hide();
}
else
{
toolBar("mainToolBar")->show();
}
slotStatusMsg(i18n("Ready."));
}
void KMouthApp::slotViewPhrasebookBar()
{
slotStatusMsg(i18n("Toggling phrasebook bar..."));
///////////////////////////////////////////////////////////////////
// turn Toolbar on or off
if(!viewPhrasebookBar->isChecked())
{
toolBar("phrasebookBar")->hide();
}
else
{
toolBar("phrasebookBar")->show();
}
slotStatusMsg(i18n("Ready."));
}
void KMouthApp::slotViewStatusBar()
{
slotStatusMsg(i18n("Toggle the statusbar..."));

@ -126,12 +126,6 @@ class KMouthApp : public TDEMainWindow
void slotViewMenuBar();
/** toggles the toolbar
*/
void slotViewToolBar();
/** toggles the phrasebook bar
*/
void slotViewPhrasebookBar();
/** toggles the statusbar
*/
void slotViewStatusBar();
/** configures the TTS system
*/

@ -245,7 +245,7 @@ bool PhraseBook::save (const KURL &url, bool asPhrasebook) {
save (*tempFile.textStream(), asPhrasebook);
tempFile.close();
return TDEIO::NetAccess::upload(tempFile.name(), url);
return TDEIO::NetAccess::upload( tempFile.name(), url, 0 );
}
}
@ -273,7 +273,7 @@ int PhraseBook::save (TQWidget *parent, const TQString &title, KURL &url, bool p
return -1;
}
if (TDEIO::NetAccess::exists(url)) {
if (TDEIO::NetAccess::exists(url, false, 0)) {
if (KMessageBox::warningContinueCancel(0,TQString("<qt>%1</qt>").arg(i18n("The file %1 already exists. "
"Do you want to overwrite it?").arg(url.url())),i18n("File Exists"),i18n("&Overwrite"))==KMessageBox::Cancel) {
return 0;
@ -334,7 +334,7 @@ bool PhraseBook::open (const KURL &url) {
fileUrl.setPath (url.url());
}
if (TDEIO::NetAccess::download (fileUrl, tempFile)) {
if (TDEIO::NetAccess::download(fileUrl, tempFile, 0)) {
TQStringList list = TQStringList();
// First: try to load it as a normal phrase book

@ -76,10 +76,10 @@ KSayItApp::KSayItApp(TQWidget* parent, const char* name, WFlags f,
initStatusBar();
initActions();
initBookmarkManager( i18n("Untitled") );
setStandardToolBarMenuEnabled(true);
createGUI(KSAYITUI);
setAutoSaveSettings("MainWindow");
readOptions();
// connect TTS plugin handler to this object
@ -121,7 +121,7 @@ KSayItApp::KSayItApp(TQWidget* parent, const char* name, WFlags f,
// init docview
// treeview->clear();
// treeview->createEmptyDocument();
slotClear();
slotClear();
}
KSayItApp::~KSayItApp()
@ -152,7 +152,6 @@ void KSayItApp::initActions()
preferences = KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(slotPreferences()), actionCollection());
KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(slotEditKeys()), actionCollection());
KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(slotConfigureToolbar()), actionCollection());
KStdAction::showToolbar("mainToolBar", actionCollection());
statusBarAction = KStdAction::showStatusbar(TQT_TQOBJECT(this), TQT_SLOT(slotToggleStatusBar()), actionCollection());
// User defined actions

Loading…
Cancel
Save