Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 121522 Details for
Bug 259710
display context elements when task is activated
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
context_problem_2nd.patch
context_problem.patch (text/plain), 5.15 KB, created by
Hiroyuki
on 2009-01-05 06:45:15 EST
(
hide
)
Description:
context_problem_2nd.patch
Filename:
MIME Type:
Creator:
Hiroyuki
Created:
2009-01-05 06:45:15 EST
Size:
5.15 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.mylyn.context.ui >Index: src/org/eclipse/mylyn/internal/context/ui/editors/ContextEditorFormPage.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.mylyn/org.eclipse.mylyn.context.ui/src/org/eclipse/mylyn/internal/context/ui/editors/ContextEditorFormPage.java,v >retrieving revision 1.65 >diff -u -r1.65 ContextEditorFormPage.java >--- src/org/eclipse/mylyn/internal/context/ui/editors/ContextEditorFormPage.java 3 Dec 2008 04:27:05 -0000 1.65 >+++ src/org/eclipse/mylyn/internal/context/ui/editors/ContextEditorFormPage.java 5 Jan 2009 11:38:41 -0000 >@@ -89,10 +89,18 @@ > > private ScrolledForm form; > >+ private Composite sectionClient; >+ > private FormToolkit toolkit; > > private CommonViewer commonViewer; > >+ private Layout commonViewerLayout; >+ >+ private Hyperlink retrieveHyperlink; >+ >+ private Layout retrieveHyperlinkLayout; >+ > private final ScalableInterestFilter interestFilter = new ScalableInterestFilter(); > > private Scale doiScale; >@@ -146,11 +154,15 @@ > > @Override > public void contextActivated(IInteractionContext context) { >+ doiScale.setEnabled(task.equals(TasksUi.getTaskActivityManager().getActiveTask())); >+ layoutDisplaySection(); > refresh(); > } > > @Override > public void contextDeactivated(IInteractionContext context) { >+ doiScale.setEnabled(task.equals(TasksUi.getTaskActivityManager().getActiveTask())); >+ layoutDisplaySection(); > refresh(); > } > >@@ -237,7 +249,8 @@ > doiScale.setLayoutData(scaleGridData); > doiScale.setPageIncrement(1); > doiScale.setMinimum(0); >- doiScale.setSelection(SCALE_STEPS / 2); >+ //doiScale.setSelection(SCALE_STEPS / 2); >+ doiScale.setSelection(0); > doiScale.setMaximum(SCALE_STEPS); > doiScale.addSelectionListener(new SelectionListener() { > public void widgetSelected(SelectionEvent e) { >@@ -429,49 +442,69 @@ > section.setText(Messages.ContextEditorFormPage_Elements); > section.setLayoutData(new GridData(GridData.FILL_BOTH)); > >- Composite sectionClient = toolkit.createComposite(section); >+ /*Composite*/sectionClient = toolkit.createComposite(section); > section.setClient(sectionClient); > >- if (task.equals(TasksUi.getTaskActivityManager().getActiveTask())) { >- sectionClient.setLayout(new Layout() { >- >- @Override >- protected Point computeSize(Composite composite, int wHint, int hHint, boolean flushCache) { >- return new Point(0, 0); >- } >+ /*Hyperlink*/retrieveHyperlink = toolkit.createHyperlink(sectionClient, >+ Messages.ContextEditorFormPage_Activate_task_to_edit_context, SWT.NONE); >+ retrieveHyperlink.addMouseListener(new MouseListener() { > >- @Override >- protected void layout(Composite composite, boolean flushCache) { >- Rectangle clientArea = composite.getClientArea(); >- commonViewer.getControl() >- .setBounds(clientArea.x, clientArea.y, clientArea.width, clientArea.height); >- } >+ public void mouseUp(MouseEvent e) { >+ new TaskActivateAction().run(task); >+ } > >- }); >- createViewer(sectionClient); >- } else { >- sectionClient.setLayout(new GridLayout()); >- Hyperlink retrieveHyperlink = toolkit.createHyperlink(sectionClient, >- Messages.ContextEditorFormPage_Activate_task_to_edit_context, SWT.NONE); >- retrieveHyperlink.addMouseListener(new MouseListener() { >+ public void mouseDoubleClick(MouseEvent e) { >+ // ignore >+ } > >- public void mouseUp(MouseEvent e) { >- new TaskActivateAction().run(task); >- } >+ public void mouseDown(MouseEvent e) { >+ // ignore >+ } >+ }); >+ retrieveHyperlink.setLayoutData(new GridData(GridData.FILL_BOTH)); > >- public void mouseDoubleClick(MouseEvent e) { >- // ignore >- } >+ createViewer(sectionClient); > >- public void mouseDown(MouseEvent e) { >- // ignore >- } >- }); >- } >+ layoutDisplaySection(); > > section.setExpanded(true); > } > >+ private void layoutDisplaySection() { >+ if (task.equals(TasksUi.getTaskActivityManager().getActiveTask())) { >+ if (commonViewerLayout == null) { >+ commonViewerLayout = new Layout() { >+ >+ @Override >+ protected Point computeSize(Composite composite, int wHint, int hHint, boolean flushCache) { >+ return new Point(0, 0); >+ } >+ >+ @Override >+ protected void layout(Composite composite, boolean flushCache) { >+ Rectangle clientArea = composite.getClientArea(); >+ commonViewer.getControl().setBounds(clientArea.x, clientArea.y, clientArea.width, >+ clientArea.height); >+ } >+ >+ }; >+ } >+ >+ sectionClient.setLayout(commonViewerLayout); >+ retrieveHyperlink.setVisible(false); >+ commonViewer.getControl().setVisible(true); >+ } else { >+ if (retrieveHyperlinkLayout == null) { >+ retrieveHyperlinkLayout = new GridLayout(); >+ } >+ >+ sectionClient.setLayout(retrieveHyperlinkLayout); >+ retrieveHyperlink.setVisible(true); >+ commonViewer.getControl().setVisible(false); >+ } >+ sectionClient.layout(); >+ } >+ > private void createViewer(Composite aParent) { > commonViewer = createCommonViewer(aParent); > commonViewer.addFilter(interestFilter);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 259710
:
121270
| 121522 |
122889