diff gui/src/editor/FileEditorTab.cpp @ 14680:628eeaf879f7 gui

Copy/Paste buttons get greyed out in the editor correctly again. Removed margin in editor tabs and status bar. * FileEditor: Removed status bar and added slot to handle changes in tabs. * FileEditorTab: Removed margen and added signal when copying is possible.
author Jacob Dawid <jacob.dawid@googlemail.com>
date Thu, 24 May 2012 12:08:53 +0200
parents 35512b788af2
children ca733a66be7a
line wrap: on
line diff
--- a/gui/src/editor/FileEditorTab.cpp	Wed May 23 16:20:29 2012 -0400
+++ b/gui/src/editor/FileEditorTab.cpp	Thu May 24 12:08:53 2012 +0200
@@ -74,6 +74,7 @@
 
   QVBoxLayout *layout = new QVBoxLayout ();
   layout->addWidget (m_editArea);
+  layout->setMargin (0);
   setLayout (layout);
 
   // connect modified signal
@@ -86,8 +87,14 @@
   newTitle (false);
 }
 
+bool
+FileEditorTab::copyAvailable ()
+{
+  return m_copyAvailable;
+}
+
 void
-FileEditorTab::closeEvent(QCloseEvent *event)
+FileEditorTab::closeEvent (QCloseEvent *event)
 {
   if (m_fileEditor->mainWindow ()->closing ())
     {
@@ -184,10 +191,8 @@
 void
 FileEditorTab::handleCopyAvailable(bool enableCopy)
 {
-  /*
-  m_copyAction->setEnabled(enableCopy);
-  m_cutAction->setEnabled(enableCopy);
-  */
+  m_copyAvailable = enableCopy;
+  emit editorStateChanged ();
 }
 
 int