Mercurial > projects > dwt-mac
diff dwt/browser/Download_1_8.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/Download_1_8.d Tue Oct 21 15:20:04 2008 +0200 +++ b/dwt/browser/Download_1_8.d Mon Dec 01 17:07:00 2008 +0100 @@ -1,5 +1,5 @@ -/******************************************************************************* - * Copyright (c) 2003, 2007 IBM Corporation and others. +/******************************************************************************* + * Copyright (c) 2003, 2008 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 * which accompanies this distribution, and is available at @@ -32,6 +32,12 @@ import dwt.widgets.Listener; import dwt.widgets.Shell; +/** + * This class implements the nsIDownload interface for mozilla + * version 1.8.x. For mozilla versions 1.4 - 1.7.x this interface + * is implemented by class nsIDownload. Mozilla versions later + * than 1.8.x do not need to call this interface. + */ class Download_1_8 { XPCOMObject supports; XPCOMObject download; @@ -258,17 +264,17 @@ } }; shell = new Shell (DWT.DIALOG_TRIM); - String msg = Compatibility.getMessage ("SWT_Download_File", new Object[] {filename}); //$NON-NLS-1$ + String msg = Compatibility.getMessage ("DWT_Download_File", new Object[] {filename}); //$NON-NLS-1$ shell.setText (msg); GridLayout gridLayout = new GridLayout (); gridLayout.marginHeight = 15; gridLayout.marginWidth = 15; gridLayout.verticalSpacing = 20; shell.setLayout (gridLayout); - msg = Compatibility.getMessage ("SWT_Download_Location", new Object[] {filename, url}); //$NON-NLS-1$ + msg = Compatibility.getMessage ("DWT_Download_Location", new Object[] {filename, url}); //$NON-NLS-1$ new Label (shell, DWT.SIMPLE).setText (msg); status = new Label (shell, DWT.SIMPLE); - msg = Compatibility.getMessage ("SWT_Download_Started"); //$NON-NLS-1$ + msg = Compatibility.getMessage ("DWT_Download_Started"); //$NON-NLS-1$ status.setText (msg); GridData data = new GridData (); data.grabExcessHorizontalSpace = true; @@ -276,7 +282,7 @@ status.setLayoutData (data); cancel = new Button (shell, DWT.PUSH); - cancel.setText (DWT.getMessage ("SWT_Cancel")); //$NON-NLS-1$ + cancel.setText (DWT.getMessage ("DWT_Cancel")); //$NON-NLS-1$ data = new GridData (); data.horizontalAlignment = GridData.CENTER; cancel.setLayoutData (data); @@ -380,7 +386,7 @@ long totalKBytes = aMaxTotalProgress / 1024; if (shell !is null && !shell.isDisposed ()) { Object[] arguments = {new Long (currentKBytes), new Long (totalKBytes)}; - String statusMsg = Compatibility.getMessage ("SWT_Download_Status", arguments); //$NON-NLS-1$ + String statusMsg = Compatibility.getMessage ("DWT_Download_Status", arguments); //$NON-NLS-1$ status.setText (statusMsg); shell.layout (true); shell.getDisplay ().update ();