Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 354342 - The version number can not be changed after the ValgrindOptionTab has been initialized
Summary: The version number can not be changed after the ValgrindOptionTab has been in...
Status: RESOLVED FIXED
Alias: None
Product: Linux Tools
Classification: Tools
Component: Valgrind (show other bugs)
Version: 0.8.0   Edit
Hardware: PC All
: P3 enhancement (vote)
Target Milestone: 0.9.0   Edit
Assignee: Elliott Baron CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 315504
  Show dependency tree
 
Reported: 2011-08-10 04:49 EDT by Ryan Xu CLA
Modified: 2011-09-21 16:09 EDT (History)
3 users (show)

See Also:


Attachments
patch v1 (1.91 KB, patch)
2011-08-10 05:34 EDT, Martin Oberhuber CLA
jjohnstn: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ryan Xu CLA 2011-08-10 04:49:10 EDT
The valgrind version number is seted when the ValgrindOptionTab is initialed and can not be changed anymore.

In some user case, maybe we need to change the version number on fly.

Can we add a setter/getter for the variable valgrindVersion?
Comment 1 Ryan Xu CLA 2011-08-10 04:57:13 EDT
If we can provide a setter/getter for the variable "valgrindVersion", after the version is changed . the control should also redraw.
Comment 2 Martin Oberhuber CLA 2011-08-10 05:11:31 EDT
Background: In our product, we run valgrind on remote targets (by extending the original Linuxtools launches).

Since a different valgrind version can be installed on different targets, and users can select a different target in the UI, it's important to be able and change the valgrind version.
Comment 3 Martin Oberhuber CLA 2011-08-10 05:34:21 EDT
Created attachment 201221 [details]
patch v1

Attached is a simple patch against master.

I don't think we can redraw controls while a tab is being displayed... I've never seen an SWT control vanish or reappear based on a change on that page (well, except a "Details>>" button in dialogs.

So my first approach is only allowing to change the valgrind version while the tab is not being displayed. That's good enough for our approach, where a different tab will pick the connection. Switching back to the valgrind tab, the tab should be redrawn.

Ryan, could you check whether that patch fits your needs?
Comment 4 Martin Oberhuber CLA 2011-09-07 05:14:48 EDT
Ping, could my patch be reviewed / considered ?

FWIW, in our commercial product we use introspection today, in order to access the private "valgrindVersion" field.
Comment 5 Jeff Johnston CLA 2011-09-08 18:02:44 EDT
(In reply to comment #4)
> Ping, could my patch be reviewed / considered ?
> 
> FWIW, in our commercial product we use introspection today, in order to access
> the private "valgrindVersion" field.

Patch is very reasonable considering that remote Valgrind version will have to be calculated once user has picked target.

Patch has been applied to master.
Comment 6 Jeff Johnston CLA 2011-09-21 16:09:34 EDT
Comment on attachment 201221 [details]
patch v1

Less than 250 lines.