Mercurial > projects > dwt-addons
comparison dwtx/jface/action/StatusLine.d @ 39:644f1334b451
fix anon classes
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Tue, 08 Apr 2008 22:05:42 +0200 |
parents | c884a1ab6db3 |
children | da5ad8eedf5d |
comparison
equal
deleted
inserted
replaced
38:c884a1ab6db3 | 39:644f1334b451 |
---|---|
114 protected static ImageDescriptor fgStopImage; | 114 protected static ImageDescriptor fgStopImage; |
115 | 115 |
116 static this() { | 116 static this() { |
117 fgStopImage = ImageDescriptor.createFromFile( | 117 fgStopImage = ImageDescriptor.createFromFile( |
118 import("dwtx.jface.action.images.stop.gif"));//$NON-NLS-1$ | 118 import("dwtx.jface.action.images.stop.gif"));//$NON-NLS-1$ |
119 JFaceResources.getImageRegistry().put( | 119 //DWT Note: Not used in jface, but needs Display instance, which is not yet available. |
120 "dwtx.jface.parts.StatusLine.stopImage", fgStopImage);//$NON-NLS-1$ | 120 // JFaceResources.getImageRegistry().put( |
121 // "dwtx.jface.parts.StatusLine.stopImage", fgStopImage);//$NON-NLS-1$ | |
121 } | 122 } |
122 | 123 |
123 /** | 124 /** |
124 * Layout the contribution item controls on the status line. | 125 * Layout the contribution item controls on the status line. |
125 */ | 126 */ |
340 long timestamp = System.currentTimeMillis(); | 341 long timestamp = System.currentTimeMillis(); |
341 fStartTime = timestamp; | 342 fStartTime = timestamp; |
342 bool animated = (totalWork is UNKNOWN || totalWork is 0); | 343 bool animated = (totalWork is UNKNOWN || totalWork is 0); |
343 // make sure the progress bar is made visible while | 344 // make sure the progress bar is made visible while |
344 // the task is running. Fixes bug 32198 for the non-animated case. | 345 // the task is running. Fixes bug 32198 for the non-animated case. |
345 Runnable timer = new class Runnable { | 346 Runnable timer = new class(animated,timestamp) Runnable { |
346 bool animated_; | 347 bool animated_; |
347 long timestamp_; | 348 long timestamp_; |
348 this(){ | 349 this(bool a,long b){ |
349 animated_=animated; | 350 animated_=a; |
350 timestamp_=timestamp; | 351 timestamp_=b; |
351 } | 352 } |
352 public void run() { | 353 public void run() { |
353 this.outer.startTask(timestamp_, animated_); | 354 this.outer.startTask(timestamp_, animated_); |
354 } | 355 } |
355 }; | 356 }; |