User forums > General (but related to Code::Blocks)

show debugger tip under curser when ctrl key is pressed

<< < (7/8) > >>

Loaden:

--- Quote from: ollydbg on December 20, 2010, 05:26:50 am ---
--- Code: ---Index: plugins/debuggergdb/debuggergdb.cpp
===================================================================
--- plugins/debuggergdb/debuggergdb.cpp (revision 6903)
+++ plugins/debuggergdb/debuggergdb.cpp (working copy)
@@ -2648,6 +2648,11 @@
     if (!Manager::Get()->GetConfigManager(_T("debugger"))->ReadBool(_T("eval_tooltip"), false))
         return;
 
+    if (!::wxGetKeyState(WXK_CONTROL))  // does not work!!!!!
+        return;
+    //if(! (::GetAsyncKeyState(VK_CONTROL)&0x80))
+    //    return;
+
     EditorBase* base = event.GetEditor();
     cbEditor* ed = base && base->IsBuiltinEditor() ? static_cast<cbEditor*>(base) : 0;
     if (!ed)
Index: sdk/wxscintilla/src/scintilla/src/Editor.cxx
===================================================================
--- sdk/wxscintilla/src/scintilla/src/Editor.cxx (revision 6903)
+++ sdk/wxscintilla/src/scintilla/src/Editor.cxx (working copy)
@@ -5379,7 +5379,10 @@
 }
 
 int Editor::KeyDown(int key, bool shift, bool ctrl, bool alt, bool *consumed) {
- DwellEnd(false);
+
+ if (!ctrl)
+    DwellEnd(false);
+
  int modifiers = (shift ? SCI_SHIFT : 0) | (ctrl ? SCI_CTRL : 0) |
         (alt ? SCI_ALT : 0);
  int msg = kmap.Find(key, modifiers);


--- End code ---

This patch try to solve the problem, but it failed. when holding the ctrl, the tip show about 0.1 second and disappeared quickly.

any one can help me? thanks.

--- End quote ---
Good catch!

oBFusCATed:
A fix for this was committed in r7397 in the debugger's branch.

ollydbg:

--- Quote from: oBFusCATed on August 29, 2011, 04:55:21 pm ---A fix for this was committed in r7397 in the debugger's branch.

--- End quote ---
would you like to do some extra enhancement? like the patch here:
hit the ctrl key to show the debug tip

oBFusCATed:
Yes, my version of this patch is to be committed in some time...

ollydbg:

--- Quote from: oBFusCATed on August 30, 2011, 09:08:18 am ---Yes, my version of this patch is to be committed in some time...

--- End quote ---
No, the rev 7397 only change one file.
But What I said is to use the full patch:
http://smrt.is-a-geek.org/codeblocks/patches/dbg/dbg_refactor0022.5.patch
Such that when you hit the ctrl, the emulated dwell event is sent.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version