User forums > Using Code::Blocks
Coming back to Orig. place after Find Implementation of xxx/ Find Declaration of
ollydbg:
After thinking carefully for a while, I get the definition of a "recorded jump"
I'm not sure how to implement this functionality, I can only recall some code when I see in "implement undo and redo". So, we can define a Forward position stack and Backword position stack. Each entry of the stack contains two values ( the file name and the position line number )
1
If I use the context menu, then select "Go to declaration... " or "Go to definition...", then the caret position will be push to the Backword position stack before each jump.
2
If I click the mouse cross tabs, which means I change edit point from A.cpp to B.cpp, the caret position in A.cpp will be recorded.
3
If I scroll in the same source file, each time I click the mouse, the plugin will check whether it is far form the last edit point, eg, if it is more than 10 lines, then, the last caret position will be recored in the backword stack.
That's the way I think browser track plugin should work. Because in the current, I always feel some annoying when I jump to some where and forget the return position. I don't think all the 4 "alt + arrow" were needed. I just think use two of them is enough, that is "Jump backward" and "Jump forward".
Thank you, I know you are the author of this great plugin. :D
MortenMacFly:
--- Quote from: ollydbg on March 08, 2009, 03:10:23 pm ---I always feel some annoying when I jump to some where and forget the return position.
--- End quote ---
BTW: Are you aware of the function "CTRL + PageUp/PageDown? This jumps to the next/previous method in the file. I use this very often to quickly navigate in a file. Hence it requires that CC has successfully parsed the methods of that file (which since ~r5000 is always the case for me...).
ollydbg:
@MortenMacFly
Thanks for the hint. In fact, I haven't heard this short-cut before. :D
But I don't think the "ctrl + pageup/down" has some relationship with CodeCompletion, it is a functionality of "scintilla control".( I tested even when i open a large project and CC is still parsing, I can jump through ctrl + pageup/down).
Jenna:
--- Quote from: ollydbg on March 08, 2009, 03:56:41 pm ---@MortenMacFly
Thanks for the hint. In fact, I haven't heard this short-cut before. :D
But I don't think the "ctrl + pageup/down" has some relationship with CodeCompletion, it is a functionality of "scintilla control".( I tested even when i open a large project and CC is still parsing, I can jump through ctrl + pageup/down).
--- End quote ---
--- Quote from: ollydbg on March 08, 2009, 03:10:23 pm ---After thinking carefully for a while,
--- End quote ---
That is something we should do more often (I mean thinking before writing).
Sometimes it's correct what a C::B dev tells you.
Look at codeompletion.cpp about line 1241: void CodeCompletion::GotoFunctionPrevNext(bool next /* = false */).
ollydbg:
@jens
Thanks, I do apologize for my carelessness. :oops:
@macfly
Sorry for my suspicion on your message. :(
Navigation
[0] Message Index
[*] Previous page
Go to full version