Mercurial > projects > dwt-mac
diff dwt/browser/HelperAppLauncherDialogFactory.d @ 45:d8635bb48c7c
Merge with SWT 3.5
author | Jacob Carlborg <doob@me.com> |
---|---|
date | Mon, 01 Dec 2008 17:07:00 +0100 |
parents | e831403a80a9 |
children | 5583f8eeee6c |
line wrap: on
line diff
--- a/dwt/browser/HelperAppLauncherDialogFactory.d Tue Oct 21 15:20:04 2008 +0200 +++ b/dwt/browser/HelperAppLauncherDialogFactory.d Mon Dec 01 17:07:00 2008 +0100 @@ -1,4 +1,4 @@ -/******************************************************************************* +/******************************************************************************* * Copyright (c) 2003, 2007 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 @@ -23,6 +23,7 @@ XPCOMObject supports; XPCOMObject factory; int refCount = 0; + bool isPre_1_9 = true; this () { createCOMInterfaces (); @@ -94,9 +95,15 @@ /* nsIFactory */ int CreateInstance (int /*long*/ aOuter, int /*long*/ iid, int /*long*/ result) { - HelperAppLauncherDialog helperAppLauncherDialog = new HelperAppLauncherDialog (); - helperAppLauncherDialog.AddRef (); - XPCOM.memmove (result, new int /*long*/[] {helperAppLauncherDialog.getAddress ()}, C.PTR_SIZEOF); + if (isPre_1_9) { + HelperAppLauncherDialog helperAppLauncherDialog = new HelperAppLauncherDialog (); + helperAppLauncherDialog.AddRef (); + XPCOM.memmove (result, new int /*long*/[] {helperAppLauncherDialog.getAddress ()}, C.PTR_SIZEOF); + } else { + HelperAppLauncherDialog_1_9 helperAppLauncherDialog = new HelperAppLauncherDialog_1_9 (); + helperAppLauncherDialog.AddRef (); + XPCOM.memmove (result, new int /*long*/[] {helperAppLauncherDialog.getAddress ()}, C.PTR_SIZEOF); + } return XPCOM.NS_OK; }