[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdeedu/kmplot/kmplot
From: Fredrik Edemar <f_edemar () linux ! se>
Date: 2005-02-26 18:56:27
Message-ID: 20050226185627.BDE8110B25 () office ! kde ! org
[Download RAW message or body]
CVS commit by fedemar:
The window caption should not include the "file:/"-prefix for the filename.
M +6 -6 MainDlg.cpp 1.151
M +7 -4 kmplot.cpp 1.10
--- kdeedu/kmplot/kmplot/kmplot.cpp #1.9:1.10
@@ -124,5 +124,8 @@ bool KmPlot::load(const KURL& url)
{
m_part->openURL( url );
- return !m_part->url().isEmpty();
+ if (m_part->url().isEmpty())
+ return false;
+ setCaption(url.prettyURL(0, KURL::StripFileProtocol));
+ return true;
}
@@ -243,5 +246,5 @@ void KmPlot::fileOpen(const KURL &url)
// in its initial state. This is what we do here..
if ( m_part->url().isEmpty() && !isModified() )
- load( KStandardDirs::realFilePath(url.url()) ); // we open \
the file in this window... + load( KStandardDirs::realFilePath(url.url())); \
// we open the file in this window... else
openFileInNewWindow(url); // we open the file in a new \
window...
--- kdeedu/kmplot/kmplot/MainDlg.cpp #1.150:1.151
@@ -276,5 +276,5 @@ void MainDlg::slotSaveas()
m_url = url;
m_recentFiles->addURL( url );
- setWindowCaption( m_url.url() );
+ setWindowCaption( m_url.prettyURL(0, KURL::StripFileProtocol) );
m_modified = false;
}
@@ -354,6 +354,6 @@ bool MainDlg::openFile()
}
m_currentfile = m_url;
- m_recentFiles->addURL( m_url );
- setWindowCaption( m_url.url() );
+ m_recentFiles->addURL( m_url.prettyURL(0, KURL::StripFileProtocol) );
+ setWindowCaption( m_url.prettyURL(0, KURL::StripFileProtocol) );
m_modified = false;
view->updateSliders();
@@ -379,10 +379,10 @@ void MainDlg::slotOpenRecent( const KURL
return;
}
+ m_url = m_currentfile = url;
m_recentFiles->setCurrentItem(-1); //don't select the item in the \
open-recent menu + setWindowCaption( m_url.prettyURL(0, KURL::StripFileProtocol) );
+ m_modified = false;
view->updateSliders();
view->drawPlot();
- m_url = url;
- setWindowCaption( url.url() );
- m_modified = false;
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic