Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
eclipse-plugin
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
5
Issues
5
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
asm
eclipse-plugin
Commits
4890f5d7
Commit
4890f5d7
authored
Jan 09, 2006
by
andrei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed update of vars/stack tables on selection in bytecode analiser pane
parent
46e42e75
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
8 deletions
+23
-8
src/de/loskutov/bco/views/BytecodeOutlineView.java
src/de/loskutov/bco/views/BytecodeOutlineView.java
+23
-8
No files found.
src/de/loskutov/bco/views/BytecodeOutlineView.java
View file @
4890f5d7
...
...
@@ -33,6 +33,7 @@ import org.eclipse.jface.action.IToolBarManager;
import
org.eclipse.jface.action.MenuManager
;
import
org.eclipse.jface.action.Separator
;
import
org.eclipse.jface.action.StatusLineManager
;
import
org.eclipse.jface.text.BadLocationException
;
import
org.eclipse.jface.text.Document
;
import
org.eclipse.jface.text.IDocument
;
import
org.eclipse.jface.text.IFindReplaceTarget
;
...
...
@@ -154,6 +155,7 @@ public class BytecodeOutlineView extends ViewPart {
protected
Action
linkWithEditorAction
;
protected
Action
selectionChangedAction
;
protected
Action
refreshVarsAndStackAction
;
protected
Action
showSelectedOnlyAction
;
protected
Action
setRawModeAction
;
protected
Action
toggleASMifierModeAction
;
...
...
@@ -470,6 +472,7 @@ public class BytecodeOutlineView extends ViewPart {
if
(
isLinkedWithEditor
())
{
selectionChangedAction
.
run
();
}
refreshVarsAndStackAction
.
run
();
}
});
...
...
@@ -480,6 +483,13 @@ public class BytecodeOutlineView extends ViewPart {
}
};
refreshVarsAndStackAction
=
new
Action
()
{
public
void
run
()
{
int
decompiledLine
=
tableControl
.
getSelectionIndex
();
updateVerifierControl
(
decompiledLine
);
}
};
linkWithEditorAction
=
new
AbstractToggleLinkingAction
()
{
public
void
run
()
{
doLinkWithEditor
=
linkWithEditorAction
.
isChecked
();
...
...
@@ -665,6 +675,7 @@ public class BytecodeOutlineView extends ViewPart {
lastChildElement
=
null
;
linkWithEditorAction
=
null
;
selectionChangedAction
=
null
;
refreshVarsAndStackAction
=
null
;
showSelectedOnlyAction
=
null
;
setRawModeAction
=
null
;
toggleASMifierModeAction
=
null
;
...
...
@@ -1046,7 +1057,7 @@ public class BytecodeOutlineView extends ViewPart {
updateStatus
(
lastDecompiledResult
,
bytecodeOffest
);
}
pr
ivate
void
updateVerifierControl
(
int
decompiledLine
)
{
pr
otected
void
updateVerifierControl
(
int
decompiledLine
)
{
lvtTable
.
removeAll
();
stackTable
.
removeAll
();
String
[][][]
frame
=
lastDecompiledResult
.
getFrameTables
(
...
...
@@ -1098,13 +1109,17 @@ public class BytecodeOutlineView extends ViewPart {
try
{
if
(
sourceLine
>
0
)
{
IRegion
lineInfo
=
javaEditor
.
getDocumentProvider
().
getDocument
(
javaEditor
.
getEditorInput
()).
getLineInformation
(
sourceLine
-
1
);
EclipseUtils
.
selectInEditor
(
javaEditor
,
lineInfo
.
getOffset
(),
lineInfo
.
getLength
());
}
if
(
verifyCode
)
{
updateVerifierControl
(
decompiledLine
);
IDocument
document
=
javaEditor
.
getDocumentProvider
()
.
getDocument
(
javaEditor
.
getEditorInput
());
try
{
IRegion
lineInfo
=
document
.
getLineInformation
(
sourceLine
-
1
);
EclipseUtils
.
selectInEditor
(
javaEditor
,
lineInfo
.
getOffset
(),
lineInfo
.
getLength
());
}
catch
(
BadLocationException
e
)
{
// do nothing. This could happens e.g. if editor does not contain
// full source code etc, so that line info is not exist in editor
}
}
}
catch
(
Exception
e
)
{
BytecodeOutlinePlugin
.
log
(
e
,
IStatus
.
ERROR
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment