Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick Tasse2015-01-19 16:06:37 +0000
committerPatrick Tasse2015-01-21 22:04:54 +0000
commitdc5f103e2d83ef6bcad3a4b1523b401f758ed037 (patch)
treeab33428476226287ea209c77052eaf31d0239d32
parent3c79c00b4b81222369fae9002cc54de300ce477c (diff)
downloadorg.eclipse.linuxtools-dc5f103e2d83ef6bcad3a4b1523b401f758ed037.tar.gz
org.eclipse.linuxtools-dc5f103e2d83ef6bcad3a4b1523b401f758ed037.tar.xz
org.eclipse.linuxtools-dc5f103e2d83ef6bcad3a4b1523b401f758ed037.zip
tmf: Bug 457852: Event table raw viewer selection not propagated
Change-Id: I50ffba62cda61811ad693d0ce6c55d3ee9c32110 Reviewed-on: https://git.eclipse.org/r/39879 Tested-by: Hudson CI Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com> Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com> (cherry picked from commit 403ec43efe86b728794b2d309b536e02c1584b1a) Reviewed-on: https://git.eclipse.org/r/40049
-rw-r--r--lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/viewers/events/TmfEventsTable.java11
1 files changed, 9 insertions, 2 deletions
diff --git a/lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/viewers/events/TmfEventsTable.java b/lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/viewers/events/TmfEventsTable.java
index 29e23dd6f8..9fbaeff9ef 100644
--- a/lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/viewers/events/TmfEventsTable.java
+++ b/lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/viewers/events/TmfEventsTable.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2010, 2014 Ericsson
+ * Copyright (c) 2010, 2015 Ericsson
*
* All rights reserved. This program and the accompanying materials are
* made available under the terms of the Eclipse Public License v1.0 which
@@ -650,10 +650,17 @@ public class TmfEventsTable extends TmfComponent implements IGotoMarker, IColorS
}
final TableItem[] selection = fTable.getSelection();
if ((selection != null) && (selection.length > 0)) {
- final TmfTimestamp ts = (TmfTimestamp) fTable.getSelection()[0].getData(Key.TIMESTAMP);
+ TableItem item = fTable.getSelection()[0];
+ final TmfTimestamp ts = (TmfTimestamp) item.getData(Key.TIMESTAMP);
if (ts != null) {
broadcast(new TmfTimeSynchSignal(TmfEventsTable.this, ts));
}
+ if (item.getData() instanceof ITmfEvent) {
+ broadcast(new TmfEventSelectedSignal(TmfEventsTable.this, (ITmfEvent) item.getData()));
+ fireSelectionChanged(new SelectionChangedEvent(TmfEventsTable.this, new StructuredSelection(item.getData())));
+ } else {
+ fireSelectionChanged(new SelectionChangedEvent(TmfEventsTable.this, StructuredSelection.EMPTY));
+ }
}
}
});

Back to the top