mirror of
https://github.com/KDE/konsole.git
synced 2026-02-05 04:41:35 -05:00
Add basic code to associate shortcuts with profiles and load/save those shortcut/profile pairs. Move Profile class into its own source file. Move old TODO list into the 'old' directory.
svn path=/trunk/KDE/kdebase/apps/konsole/; revision=664308
This commit is contained in:
@@ -58,20 +58,14 @@ MainWindow::MainWindow()
|
||||
_bookmarkHandler(0),
|
||||
_pluggedController(0)
|
||||
{
|
||||
// add a small amount of space between the top of the window and the main widget
|
||||
// to prevent the menu bar and main widget borders touching (which looks very ugly) in styles
|
||||
// where the menu bar has a lower border
|
||||
//setContentsMargins(0,2,0,0);
|
||||
|
||||
// create actions for menus
|
||||
// the directory ('konsole') is included in the path here so that the XML
|
||||
// file can be found when this code is being used in the Konsole part.
|
||||
setXMLFile("konsole/konsoleui.rc");
|
||||
setupActions();
|
||||
|
||||
// create view manager
|
||||
// the directory ('konsole') is included in the path here so that the XML
|
||||
// file can be found when this code is being used in the Konsole part.
|
||||
//setXMLFile("konsole/konsoleui.rc");
|
||||
_viewManager = new ViewManager(this,actionCollection());
|
||||
_viewManager = new ViewManager(this,actionCollection());
|
||||
connect( _viewManager , SIGNAL(empty()) , this , SLOT(close()) );
|
||||
connect( _viewManager , SIGNAL(activeViewChanged(SessionController*)) , this ,
|
||||
SLOT(activeViewChanged(SessionController*)) );
|
||||
@@ -256,27 +250,6 @@ void MainWindow::showRemoteConnectionDialog()
|
||||
emit requestSession(dialog.sessionKey(),_viewManager);
|
||||
}
|
||||
|
||||
void MainWindow::mergeWindows()
|
||||
{
|
||||
// merges all of the open Konsole windows into this window
|
||||
// by merging the view manager associated with the other Konsole windows
|
||||
// into this window's view manager
|
||||
|
||||
QListIterator<QWidget*> topLevelIter( QApplication::topLevelWidgets() );
|
||||
|
||||
while (topLevelIter.hasNext())
|
||||
{
|
||||
QWidget* w = topLevelIter.next();
|
||||
qDebug() << "Top level widget: " << w->metaObject()->className();
|
||||
MainWindow* window = qobject_cast<MainWindow*>(w);
|
||||
if ( window && window != this )
|
||||
{
|
||||
_viewManager->merge( window->_viewManager );
|
||||
//window->close();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void MainWindow::setupWidgets()
|
||||
{
|
||||
QWidget* widget = new QWidget(this);
|
||||
|
||||
Reference in New Issue
Block a user