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 72244 Details for
Bug 194070
Query/category tooltip should show number of open issues
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
"open" label and few other tweaks
clipboard.txt (text/plain), 6.47 KB, created by
Eugene Kuleshov
on 2007-06-23 12:31:19 EDT
(
hide
)
Description:
"open" label and few other tweaks
Filename:
MIME Type:
Creator:
Eugene Kuleshov
Created:
2007-06-23 12:31:19 EDT
Size:
6.47 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.mylyn.tasks.ui >Index: src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListToolTipHandler.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.mylyn/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListToolTipHandler.java,v >retrieving revision 1.45 >diff -u -r1.45 TaskListToolTipHandler.java >--- src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListToolTipHandler.java 23 Jun 2007 02:30:17 -0000 1.45 >+++ src/org/eclipse/mylyn/internal/tasks/ui/views/TaskListToolTipHandler.java 23 Jun 2007 16:27:07 -0000 >@@ -15,6 +15,7 @@ > package org.eclipse.mylyn.internal.tasks.ui.views; > > import java.text.DateFormat; >+import java.text.SimpleDateFormat; > import java.util.Calendar; > import java.util.Date; > >@@ -165,10 +166,9 @@ > Date date = task.getScheduledForDate(); > if (date != null) { > sb.append("Scheduled for: "); >+ sb.append(new SimpleDateFormat("E").format(date)).append(", "); > sb.append(DateFormat.getDateInstance(DateFormat.LONG).format(date)); >- sb.append(" ("); >- sb.append(DateFormat.getTimeInstance(DateFormat.SHORT).format(date)); >- sb.append(")\n"); >+ sb.append(" (").append(DateFormat.getTimeInstance(DateFormat.SHORT).format(date)).append(")\n"); > } > > long elapsed = TasksUiPlugin.getTaskListManager().getElapsedTime(task); >@@ -239,7 +239,7 @@ > } > } > >- String text = "Completed " + completed + " of " + total; >+ String text = "Open: " + (total - completed) + " Completed: " + completed + " Total: " + total; > return new ProgressData(completed, total, text); > } > >@@ -407,8 +407,8 @@ > tipShell = new Shell(parent.getDisplay(), SWT.TOOL | SWT.NO_FOCUS | SWT.MODELESS | SWT.ON_TOP); > GridLayout gridLayout = new GridLayout(); > gridLayout.numColumns = 2; >- gridLayout.marginWidth = 2; >- gridLayout.marginHeight = 2; >+ gridLayout.marginWidth = 5; >+ gridLayout.marginHeight = 5; > tipShell.setLayout(gridLayout); > tipShell.setBackground(tipShell.getDisplay().getSystemColor(SWT.COLOR_INFO_BACKGROUND)); > >@@ -416,11 +416,6 @@ > > addIconAndLabel(tipShell, null, detailsText); > >- String statusText = getStatusText(element); >- if (statusText != null) { >- addIconAndLabel(tipShell, TasksUiImages.getImage(TasksUiImages.WARNING), statusText); >- } >- > String activityText = getActivityText(element); > if (activityText != null) { > addIconAndLabel(tipShell, TasksUiImages.getImage(TasksUiImages.CALENDAR), activityText); >@@ -433,39 +428,47 @@ > > ProgressData progress = getProgressData(element); > if (progress != null) { >- addLabel(tipShell, progress.text); >+ addIconAndLabel(tipShell, null, progress.text); > >+ // label height need to be set to 0 to remove gap below the progress bar >+ Label label = new Label(tipShell, SWT.NONE); >+ GridData labelGridData = new GridData(SWT.FILL, SWT.TOP, true, false); >+ labelGridData.heightHint = 0; >+ label.setLayoutData(labelGridData); >+ > Composite progressComposite = new Composite(tipShell, SWT.NONE); > GridLayout progressLayout = new GridLayout(1, false); >- progressLayout.marginWidth = 2; >+ progressLayout.marginWidth = 0; > progressLayout.marginHeight = 0; >- progressLayout.marginBottom = 2; >- progressLayout.horizontalSpacing = 0; >- progressLayout.verticalSpacing = 0; > progressComposite.setLayout(progressLayout); >- progressComposite.setLayoutData(new GridData(SWT.FILL, SWT.DEFAULT, true, false, 4, 1)); >+ progressComposite.setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false)); > > WorkweekProgressBar taskProgressBar = new WorkweekProgressBar(progressComposite); >- taskProgressBar.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true)); >+ taskProgressBar.setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false)); > taskProgressBar.reset(progress.completed, progress.total); >+ >+ // do we really need custom canvas? this work just as fine >+// IThemeManager themeManager = PlatformUI.getWorkbench().getThemeManager(); >+// Color color = themeManager.getCurrentTheme().getColorRegistry().get( >+// TaskListColorsAndFonts.THEME_COLOR_TASK_TODAY_COMPLETED); >+// ProgressBar bar = new ProgressBar(tipShell, SWT.SMOOTH); >+// bar.setForeground(color); >+// bar.setSelection((int) (100d * progress.completed / progress.total)); >+// GridData gridData = new GridData(SWT.FILL, SWT.TOP, true, false); >+// gridData.heightHint = 5; >+// bar.setLayoutData(gridData); > } > >+ String statusText = getStatusText(element); >+ if (statusText != null) { >+ addIconAndLabel(tipShell, TasksUiImages.getImage(TasksUiImages.WARNING), statusText); >+ } >+ > tipShell.pack(); > setHoverLocation(tipShell, location); > tipShell.setVisible(true); > } > >- private void addLabel(Shell parent, String text) { >- Label textLabel = new Label(parent, SWT.NONE); >- textLabel.setForeground(parent.getDisplay().getSystemColor(SWT.COLOR_INFO_FOREGROUND)); >- textLabel.setBackground(parent.getDisplay().getSystemColor(SWT.COLOR_INFO_BACKGROUND)); >- textLabel.setAlignment(SWT.CENTER); >- GridData gd = new GridData(GridData.FILL_HORIZONTAL | GridData.VERTICAL_ALIGN_CENTER); >- gd.horizontalSpan = 2; >- textLabel.setLayoutData(gd); >- textLabel.setText(removeTrailingNewline(text)); >- } >- > private String removeTrailingNewline(String text) { > if (text.endsWith("\n")) { > return text.substring(0, text.length() - 1); >@@ -477,15 +480,13 @@ > Label imageLabel = new Label(parent, SWT.NONE); > imageLabel.setForeground(parent.getDisplay().getSystemColor(SWT.COLOR_INFO_FOREGROUND)); > imageLabel.setBackground(parent.getDisplay().getSystemColor(SWT.COLOR_INFO_BACKGROUND)); >- GridData gd = new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING | GridData.VERTICAL_ALIGN_BEGINNING); >- imageLabel.setLayoutData(gd); >+ imageLabel.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING | GridData.VERTICAL_ALIGN_BEGINNING)); > imageLabel.setImage(image); > > Label textLabel = new Label(parent, SWT.NONE); > textLabel.setForeground(parent.getDisplay().getSystemColor(SWT.COLOR_INFO_FOREGROUND)); > textLabel.setBackground(parent.getDisplay().getSystemColor(SWT.COLOR_INFO_BACKGROUND)); >- gd = new GridData(GridData.FILL_HORIZONTAL | GridData.VERTICAL_ALIGN_CENTER); >- textLabel.setLayoutData(gd); >+ textLabel.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | GridData.VERTICAL_ALIGN_CENTER)); > textLabel.setText(removeTrailingNewline(text)); > }
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 194070
: 72244 |
72245
|
72308
|
72322