Merge last PGO-green changeset from m-i to m-c.
0
browser/devtools/commandline/test/browser_cmd_pref.js
Normal file → Executable file
0
browser/devtools/commandline/test/browser_cmd_settings.js
Normal file → Executable file
0
browser/themes/gnomestripe/downloads/buttons.png
Executable file → Normal file
Before Width: | Height: | Size: 2.4 KiB After Width: | Height: | Size: 2.4 KiB |
0
browser/themes/pinstripe/downloads/buttons.png
Executable file → Normal file
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
0
browser/themes/winstripe/downloads/buttons-aero.png
Executable file → Normal file
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 3.1 KiB |
0
browser/themes/winstripe/downloads/buttons.png
Executable file → Normal file
Before Width: | Height: | Size: 3.2 KiB After Width: | Height: | Size: 3.2 KiB |
@ -49,11 +49,17 @@ private:
|
||||
nsresult rv = NS_OK;
|
||||
if (!mCanceled) {
|
||||
rv = CancelableRun();
|
||||
mParent->RemoveRunnable(this);
|
||||
|
||||
nsCOMPtr<nsIRunnable> event = NS_NewRunnableMethod(this, &CancelableRunnable::RemoveRunnable);
|
||||
NS_DispatchToMainThread(event);
|
||||
}
|
||||
return rv;
|
||||
}
|
||||
|
||||
void RemoveRunnable() {
|
||||
mParent->RemoveRunnable(this);
|
||||
}
|
||||
|
||||
void Cancel() {
|
||||
mCanceled = true;
|
||||
}
|
||||
@ -184,9 +190,11 @@ private:
|
||||
|
||||
protected:
|
||||
void AddRunnable(CancelableRunnable* aRunnable) {
|
||||
NS_ASSERTION(NS_IsMainThread(), "Wrong thread!");
|
||||
mRunnables.AppendElement(aRunnable);
|
||||
}
|
||||
void RemoveRunnable(CancelableRunnable* aRunnable) {
|
||||
NS_ASSERTION(NS_IsMainThread(), "Wrong thread!");
|
||||
mRunnables.RemoveElement(aRunnable);
|
||||
}
|
||||
nsTArray<nsRefPtr<CancelableRunnable> > mRunnables;
|
||||
|