changeset 20312:48d9001bdee3

Avoid HAVE_ macros in header file. * octave-qscintilla.h, octave-qscintilla.cc (octave_qscintilla::contextMenuEvent): Define unconditionally.
author John W. Eaton <jwe@octave.org>
date Wed, 24 Jun 2015 11:53:33 -0400
parents 396e9cd6cd98
children 3b25741a9927
files libgui/src/m-editor/octave-qscintilla.cc libgui/src/m-editor/octave-qscintilla.h
diffstat 2 files changed, 3 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/libgui/src/m-editor/octave-qscintilla.cc	Wed Jun 24 11:51:06 2015 -0400
+++ b/libgui/src/m-editor/octave-qscintilla.cc	Wed Jun 24 11:53:33 2015 -0400
@@ -183,11 +183,11 @@
     contextmenu_run (true);
 }
 
-#ifdef HAVE_QSCI_VERSION_2_6_0
 // context menu requested
 void
 octave_qscintilla::contextMenuEvent (QContextMenuEvent *e)
 {
+#ifdef HAVE_QSCI_VERSION_2_6_0
   QPoint global_pos, local_pos;                         // the menu's position
   QMenu *context_menu = createStandardContextMenu ();  // standard menu
 
@@ -235,8 +235,8 @@
 
   // finaly show the menu
   context_menu->exec (global_pos);
+#endif
 }
-#endif
 
 
 // handle the menu entry for calling help or doc
--- a/libgui/src/m-editor/octave-qscintilla.h	Wed Jun 24 11:51:06 2015 -0400
+++ b/libgui/src/m-editor/octave-qscintilla.h	Wed Jun 24 11:53:33 2015 -0400
@@ -38,9 +38,8 @@
   octave_qscintilla (QWidget *p);
   ~octave_qscintilla ();
 
-#ifdef HAVE_QSCI_VERSION_2_6_0
   virtual void contextMenuEvent (QContextMenuEvent *e);
-#endif
+
   void context_help_doc (bool);
   void context_edit ();
   void context_run ();