OSDN Git Service

Merge branch 'master' of git@scm.dev.nokia.troll.no:creator/mainline
authormae <qtc-committer@nokia.com>
Mon, 2 Feb 2009 20:58:54 +0000 (21:58 +0100)
committermae <qtc-committer@nokia.com>
Mon, 2 Feb 2009 20:58:54 +0000 (21:58 +0100)
1  2 
src/plugins/coreplugin/editormanager/editormanager.cpp
src/plugins/coreplugin/editormanager/openeditorsview.cpp
src/plugins/projectexplorer/projecttreewidget.cpp

@@@ -69,12 -70,22 +69,13 @@@ OpenEditorsWidget::OpenEditorsWidget(
      m_ui.editorList->setTextElideMode(Qt::ElideMiddle);
      m_ui.editorList->installEventFilter(this);
      m_ui.editorList->setFrameStyle(QFrame::NoFrame);
+     m_ui.editorList->setAttribute(Qt::WA_MacShowFocusRect, false);
      EditorManager *em = EditorManager::instance();
 -    foreach (IEditor *editor, em->openedEditors()) {
 -        registerEditor(editor);
 -    }
 -    connect(em, SIGNAL(editorOpened(Core::IEditor*)),
 -            this, SLOT(registerEditor(Core::IEditor*)));
 -    connect(em, SIGNAL(editorsClosed(QList<Core::IEditor*>)),
 -            this, SLOT(unregisterEditors(QList<Core::IEditor*>)));
 -    connect(em, SIGNAL(editorGroupsChanged()),
 -            this, SLOT(updateEditorList()));
 +    m_ui.editorList->setModel(em->openedEditorsModel());
      connect(em, SIGNAL(currentEditorChanged(Core::IEditor*)),
 -            this, SLOT(updateCurrentItem()));
 -    connect(m_ui.editorList, SIGNAL(itemActivated(QTreeWidgetItem*, int)),
 -            this, SLOT(selectEditor(QTreeWidgetItem*)));
 -    updateEditorList();
 +            this, SLOT(updateCurrentItem(Core::IEditor*)));
 +    connect(m_ui.editorList, SIGNAL(activated(QModelIndex)),
 +            this, SLOT(selectEditor(QModelIndex)));
  }
  
  OpenEditorsWidget::~OpenEditorsWidget()