org.eclipse.swt.win32.win32.x86_3.7.2.v3740f

method12(int[] args)
  {
    return -2147467263;
  }
  
  public int method13(int[] args)
  {
    return this$0.setToolbarsVisible(args[0], args[1]);
  }
  
  public int method14(int[] args)
  {
    return -2147467263;
  }
  
  public int method15(int[] args)
  {
    return this$0.setStatusBarVisible(args[0], args[1]);
  }
  
  public int method16(int[] args)
  {
    return -2147467263;
  }
  
  public int method17(int[] args)
  {
    return -2147467263;
  }
  
  public int method18(int[] args)
  {
    return this$0.setFrame(args[0], args[1]);
  }
  
  public int method19(int[] args)
  {
    return -2147467263;
  }
  
  public int method20(int[] args)
  {
    return -2147467263;
  }
  
  public int method21(int[] args)
  {
    return -2147467263;
  }
  
  public int method22(int[] args)
  {
    return this$0.runJavaScriptAlertPanelWithMessage(args[0], args[1]);
  }
  
  public int method23(int[] args)
  {
    return this$0.runJavaScriptConfirmPanelWithMessage(args[0], args[1], args[2]);
  }
  
  public int method24(int[] args)
  {
    return this$0.runJavaScriptTextInputPanelWithPrompt(args[0], args[1], args[2], args[3]);
  }
  
  public int method25(int[] args)
  {
    return this$0.runBeforeUnloadConfirmPanelWithMessage(args[0], args[1], args[2], args[3]);
  }
  
  public int method26(int[] args)
  {
    return this$0.runOpenPanelForFileButtonWithResultListener(args[0], args[1]);
  }
  
  public int method27(int[] args)
  {
    return this$0.mouseDidMoveOverElement(args[0], args[1], args[2]);
  }
  
  public int method28(int[] args)
  {
    return this$0.contextMenuItemsForElement(args[0], args[1], args[2], args[3]);
  }
  
  public int method29(int[] args)
  {
    return -2147467263;
  }
  
  public int method30(int[] args)
  {
    return -2147467263;
  }
  
  public int method31(int[] args)
  {
    return -2147467263;
  }
  
  public int method32(int[] args)
  {
    return -2147467263;
  }
  
  public int method33(int[] args)
  {
    return -2147467263;
  }
  
  public int method34(int[] args)
  {
    return -2147467263;
  }
  
  public int method35(int[] args)
  {
    return -2147467263;
  }
  
  public int method36(int[] args)
  {
    return -2147467263;
  }
  
  public int method37(int[] args)
  {
    return -2147467263;
  }
  
  public int method38(int[] args)
  {
    return -2147467263;
  }
  
  public int method39(int[] args)
  {
    return -2147467263;
  }
  
  public int method40(int[] args)
  {
    return -2147467263;
  }
  
  public int method41(int[] args)
  {
    return -2147467263;
  }
  
  public int method42(int[] args)
  {
    return this$0.canTakeFocus(args[0], args[1], args[2]);
  }
  
  public int method43(int[] args)
  {
    return this$0.takeFocus(args[0], args[1]);
  }
  
  public int method44(int[] args)
  {
    return -2147467263;
  }
  
  public int method45(int[] args)
  {
    return 0;
  }
  
  public int method46(int[] args)
  {
    return -2147467263;
  }
  
  public int method47(int[] args)
  {
    return -2147467263;
  }
  
  public int method48(int[] args)
  {
    return -2147467263;
  }
  
  public int method49(int[] args)
  {
    return -2147467263;
  }
  
  public int method50(int[] args)
  {
    return -2147467263;
  }
  
  public int method51(int[] args)
  {
    return this$0.printFrame(args[0], args[1]);
  }
  
  public int method52(int[] args)
  {
    return -2147467263;
  }
  
  public int method53(int[] args)
  {
    return -2147467263;
  }
  
  public int method54(int[] args)
  {
    return -2147467263;
  }
  
  public int method55(int[] args)
  {
    return -2147467263;
  }
  
  public int method56(int[] args)
  {
    return -2147467263;
  }
  
  public int method57(int[] args)
  {
    return -2147467263;
  }
  
  public int method58(int[] args)
  {
    return -2147467263;
  }
  
  public int method59(int[] args)
  {
    return -2147467263;
  }
  
  public int method60(int[] args)
  {
    return -2147467263;
  }
  
  public int method61(int[] args)
  {
    return -2147467263;
  }
  
  public int method62(int[] args)
  {
    return this$0.setMenuBarVisible(args[0], args[1]);
  }
  
  public int method63(int[] args)
  {
    return -2147467263;
  }
  
  public int method64(int[] args)
  {
    return -2147467263;
  }
  
  public int method65(int[] args)
  {
    return -2147467263;
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WebUIDelegate.1
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.widgets.Shell;

class WebUIDelegate$2
  extends SelectionAdapter
{
  final WebUIDelegate this$0;
  private final Shell val$dialog;
  
  WebUIDelegate$2(WebUIDelegate paramWebUIDelegate, Shell paramShell)
  {
    this$0 = paramWebUIDelegate;val$dialog = paramShell;
  }
  
  public void widgetSelected(SelectionEvent e)
  {
    val$dialog.dispose();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WebUIDelegate.2
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.widgets.Shell;

class WebUIDelegate$3
  extends SelectionAdapter
{
  final WebUIDelegate this$0;
  private final int[] val$result;
  private final Shell val$dialog;
  
  WebUIDelegate$3(WebUIDelegate paramWebUIDelegate, int[] paramArrayOfInt, Shell paramShell)
  {
    this$0 = paramWebUIDelegate;val$result = paramArrayOfInt;val$dialog = paramShell;
  }
  
  public void widgetSelected(SelectionEvent e)
  {
    val$result[0] = 32;
    val$dialog.dispose();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WebUIDelegate.3
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.widgets.Shell;

class WebUIDelegate$4
  extends SelectionAdapter
{
  final WebUIDelegate this$0;
  private final int[] val$result;
  private final Shell val$dialog;
  
  WebUIDelegate$4(WebUIDelegate paramWebUIDelegate, int[] paramArrayOfInt, Shell paramShell)
  {
    this$0 = paramWebUIDelegate;val$result = paramArrayOfInt;val$dialog = paramShell;
  }
  
  public void widgetSelected(SelectionEvent e)
  {
    val$result[0] = 256;
    val$dialog.dispose();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WebUIDelegate.4
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.swt.widgets.Text;

class WebUIDelegate$5
  extends SelectionAdapter
{
  final WebUIDelegate this$0;
  private final String[] val$result;
  private final Text val$textBox;
  private final Shell val$dialog;
  
  WebUIDelegate$5(WebUIDelegate paramWebUIDelegate, String[] paramArrayOfString, Text paramText, Shell paramShell)
  {
    this$0 = paramWebUIDelegate;val$result = paramArrayOfString;val$textBox = paramText;val$dialog = paramShell;
  }
  
  public void widgetSelected(SelectionEvent e)
  {
    val$result[0] = val$textBox.getText();
    val$dialog.dispose();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WebUIDelegate.5
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.widgets.Shell;

class WebUIDelegate$6
  extends SelectionAdapter
{
  final WebUIDelegate this$0;
  private final Shell val$dialog;
  
  WebUIDelegate$6(WebUIDelegate paramWebUIDelegate, Shell paramShell)
  {
    this$0 = paramWebUIDelegate;val$dialog = paramShell;
  }
  
  public void widgetSelected(SelectionEvent e)
  {
    val$dialog.dispose();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WebUIDelegate.6
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.graphics.Image;
import org.eclipse.swt.graphics.Point;
import org.eclipse.swt.graphics.Rectangle;
import org.eclipse.swt.internal.C;
import org.eclipse.swt.internal.Compatibility;
import org.eclipse.swt.internal.ole.win32.COM;
import org.eclipse.swt.internal.ole.win32.COMObject;
import org.eclipse.swt.internal.ole.win32.GUID;
import org.eclipse.swt.internal.ole.win32.IPropertyBag;
import org.eclipse.swt.internal.ole.win32.IUnknown;
import org.eclipse.swt.internal.ole.win32.VARIANT;
import org.eclipse.swt.internal.webkit.IWebDataSource;
import org.eclipse.swt.internal.webkit.IWebFrame;
import org.eclipse.swt.internal.webkit.IWebFramePrivate;
import org.eclipse.swt.internal.webkit.IWebOpenPanelResultListener;
import org.eclipse.swt.internal.webkit.IWebURLRequest;
import org.eclipse.swt.internal.webkit.IWebView;
import org.eclipse.swt.internal.webkit.WebKit_win32;
import org.eclipse.swt.internal.win32.DOCINFO;
import org.eclipse.swt.internal.win32.OS;
import org.eclipse.swt.internal.win32.PRINTDLG;
import org.eclipse.swt.internal.win32.RECT;
import org.eclipse.swt.internal.win32.TCHAR;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Event;
import org.eclipse.swt.widgets.FileDialog;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Menu;
import org.eclipse.swt.widgets.MessageBox;
import org.eclipse.swt.widgets.Monitor;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.swt.widgets.Text;

class WebUIDelegate
{
  COMObject iWebUIDelegate;
  int refCount = 0;
  String lastHoveredLinkURL;
  Browser browser;
  Point size;
  Point location;
  boolean menuBar = true;
  boolean toolBar = true;
  boolean statusBar = true;
  boolean prompt = true;
  
  WebUIDelegate(Browser browser)
  {
    createCOMInterfaces();
    this.browser = browser;
  }
  
  int AddRef()
  {
    refCount += 1;
    return refCount;
  }
  
  int canTakeFocus(int sender, int forward, int result)
  {
    OS.MoveMemory(result, new int[] { 1 }, 4);
    return 0;
  }
  
  int contextMenuItemsForElement(int sender, int element, int defaultItemsHMenu, int resultHMenu)
  {
    Point pt = browser.getDisplay().getCursorLocation();
    Event event = new Event();
    x = x;
    y = y;
    browser.notifyListeners(35, event);
    if (doit)
    {
      Menu menu = browser.getMenu();
      if ((menu != null) && (!menu.isDisposed()))
      {
        if ((x != x) || (y != y)) {
          menu.setLocation(x, y);
        }
        menu.setVisible(true);
      }
      else
      {
        OS.MoveMemory(resultHMenu, new int[] { defaultItemsHMenu }, C.PTR_SIZEOF);
        return 0;
      }
    }
    OS.MoveMemory(resultHMenu, new int[1], C.PTR_SIZEOF);
    return 0;
  }
  
  void createCOMInterfaces()
  {
    iWebUIDelegate = new COMObject(new int[] { 2, 0, 0, 3, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 4, 4, 2, 3, 4, 4, 3, 3, 3, 3, 5, 3, 1, 3, 2, 2, 2, 2, 3, 2, 3, 1, 1, 0, 0, 1, 1, 2, 2, 2, 2, 3, 5, 2, 2, 3, 1, 2, 2, 4, 10, 3 })
    {
      public int method0(int[] args)
      {
        return QueryInterface(args[0], args[1]);
      }
      
      public int method1(int[] args)
      {
        return AddRef();
      }
      
      public int method2(int[] args)
      {
        return Release();
      }
      
      public int method3(int[] args)
      {
        return createWebViewWithRequest(args[0], args[1], args[2]);
      }
      
      public int method4(int[] args)
      {
        return webViewShow(args[0]);
      }
      
      public int method5(int[] args)
      {
        return webViewClose(args[0]);
      }
      
      public int method6(int[] args)
      {
        return -2147467263;
      }
      
      public int method7(int[] args)
      {
        return -2147467263;
      }
      
      public int method8(int[] args)
      {
        return -2147467263;
      }
      
      public int method9(int[] args)
      {
        return -2147467263;
      }
      
      public int method10(int[] args)
      {
        return setStatusText(args[0], args[1]);
      }
      
      public int method11(int[] args)
      {
        return -2147467263;
      }
      
      public int method12(int[] args)
      {
        return -2147467263;
      }
      
      public int method13(int[] args)
      {
        return setToolbarsVisible(args[0], args[1]);
      }
      
      public int method14(int[] args)
      {
        return -2147467263;
      }
      
      public int method15(int[] args)
      {
        return setStatusBarVisible(args[0], args[1]);
      }
      
      public int method16(int[] args)
      {
        return -2147467263;
      }
      
      public int method17(int[] args)
      {
        return -2147467263;
      }
      
      public int method18(int[] args)
      {
        return setFrame(args[0], args[1]);
      }
      
      public int method19(int[] args)
      {
        return -2147467263;
      }
      
      public int method20(int[] args)
      {
        return -2147467263;
      }
      
      public int method21(int[] args)
      {
        return -2147467263;
      }
      
      public int method22(int[] args)
      {
        return runJavaScriptAlertPanelWithMessage(args[0], args[1]);
      }
      
      public int method23(int[] args)
      {
        return runJavaScriptConfirmPanelWithMessage(args[0], args[1], args[2]);
      }
      
      public int method24(int[] args)
      {
        return runJavaScriptTextInputPanelWithPrompt(args[0], args[1], args[2], args[3]);
      }
      
      public int method25(int[] args)
      {
        return runBeforeUnloadConfirmPanelWithMessage(args[0], args[1], args[2], args[3]);
      }
      
      public int method26(int[] args)
      {
        return runOpenPanelForFileButtonWithResultListener(args[0], args[1]);
      }
      
      public int method27(int[] args)
      {
        return mouseDidMoveOverElement(args[0], args[1], args[2]);
      }
      
      public int method28(int[] args)
      {
        return contextMenuItemsForElement(args[0], args[1], args[2], args[3]);
      }
      
      public int method29(int[] args)
      {
        return -2147467263;
      }
      
      public int method30(int[] args)
      {
        return -2147467263;
      }
      
      public int method31(int[] args)
      {
        return -2147467263;
      }
      
      public int method32(int[] args)
      {
        return -2147467263;
      }
      
      public int method33(int[] args)
      {
        return -2147467263;
      }
      
      public int method34(int[] args)
      {
        return -2147467263;
      }
      
      public int method35(int[] args)
      {
        return -2147467263;
      }
      
      public int method36(int[] args)
      {
        return -2147467263;
      }
      
      public int method37(int[] args)
      {
        return -2147467263;
      }
      
      public int method38(int[] args)
      {
        return -2147467263;
      }
      
      public int method39(int[] args)
      {
        return -2147467263;
      }
      
      public int method40(int[] args)
      {
        return -2147467263;
      }
      
      public int method41(int[] args)
      {
        return -2147467263;
      }
      
      public int method42(int[] args)
      {
        return canTakeFocus(args[0], args[1], args[2]);
      }
      
      public int method43(int[] args)
      {
        return takeFocus(args[0], args[1]);
      }
      
      public int method44(int[] args)
      {
        return -2147467263;
      }
      
      public int method45(int[] args)
      {
        return 0;
      }
      
      public int method46(int[] args)
      {
        return -2147467263;
      }
      
      public int method47(int[] args)
      {
        return -2147467263;
      }
      
      public int method48(int[] args)
      {
        return -2147467263;
      }
      
      public int method49(int[] args)
      {
        return -2147467263;
      }
      
      public int method50(int[] args)
      {
        return -2147467263;
      }
      
      public int method51(int[] args)
      {
        return printFrame(args[0], args[1]);
      }
      
      public int method52(int[] args)
      {
        return -2147467263;
      }
      
      public int method53(int[] args)
      {
        return -2147467263;
      }
      
      public int method54(int[] args)
      {
        return -2147467263;
      }
      
      public int method55(int[] args)
      {
        return -2147467263;
      }
      
      public int method56(int[] args)
      {
        return -2147467263;
      }
      
      public int method57(int[] args)
      {
        return -2147467263;
      }
      
      public int method58(int[] args)
      {
        return -2147467263;
      }
      
      public int method59(int[] args)
      {
        return -2147467263;
      }
      
      public int method60(int[] args)
      {
        return -2147467263;
      }
      
      public int method61(int[] args)
      {
        return -2147467263;
      }
      
      public int method62(int[] args)
      {
        return setMenuBarVisible(args[0], args[1]);
      }
      
      public int method63(int[] args)
      {
        return -2147467263;
      }
      
      public int method64(int[] args)
      {
        return -2147467263;
      }
      
      public int method65(int[] args)
      {
        return -2147467263;
      }
    };
  }
  
  int createWebViewWithRequest(int sender, int request, int webView)
  {
    WindowEvent newEvent = new WindowEvent(this.browser);
    display = this.browser.getDisplay();
    widget = this.browser;
    required = true;
    OpenWindowListener[] openWindowListeners = browserwebBrowser.openWindowListeners;
    for (int i = 0; i < openWindowListeners.length; i++) {
      openWindowListeners[i].open(newEvent);
    }
    IWebView iwebview = null;
    Browser browser = null;
    if ((browser != null) && ((browser.webBrowser instanceof WebKit))) {
      browser = browser;
    }
    if ((browser != null) && (!browser.isDisposed()))
    {
      iwebview = webBrowser).webView;
      OS.MoveMemory(webView, new int[] { iwebview.getAddress() }, OS.PTR_SIZEOF);
      if (request != 0)
      {
        IWebURLRequest req = new IWebURLRequest(request);
        int[] result = new int[1];
        int hr = req.URL(result);
        if ((hr != 0) || (result[0] == 0)) {
          return 0;
        }
        String sUrl = WebKit.extractBSTR(result[0]);
        COM.SysFreeString(result[0]);
        if (sUrl.length() != 0)
        {
          result[0] = 0;
          hr = iwebview.mainFrame(result);
          if ((hr != 0) || (result[0] == 0)) {
            return 0;
          }
          IWebFrame mainFrame = new IWebFrame(result[0]);
          mainFrame.loadRequest(req.getAddress());
          mainFrame.Release();
        }
      }
      return 0;
    }
    return -2147467263;
  }
  
  protected void disposeCOMInterfaces()
  {
    if (iWebUIDelegate != null)
    {
      iWebUIDelegate.dispose();
      iWebUIDelegate = null;
    }
  }
  
  int getAddress()
  {
    return iWebUIDelegate.getAddress();
  }
  
  int mouseDidMoveOverElement(int sender, int elementInformation, int modifierFlags)
  {
    if (elementInformation == 0) {
      return 0;
    }
    IPropertyBag info = new IPropertyBag(elementInformation);
    int key = WebKit.createBSTR("WebElementLinkURLKey");
    int hHeap = OS.GetProcessHeap();
    int resultPtr = OS.HeapAlloc(hHeap, 8, VARIANT.sizeof);
    int hr = info.Read(key, resultPtr, null);
    if ((hr != 0) || (resultPtr == 0)) {
      return 0;
    }
    String value = null;
    VARIANT v = new VARIANT();
    COM.MoveMemory(v, resultPtr, VARIANT.sizeof);
    if (vt == 8) {
      value = WebKit.extractBSTR(lVal);
    }
    OS.HeapFree(hHeap, 0, resultPtr);
    StatusTextListener[] statusTextListeners = browser.webBrowser.statusTextListeners;
    if ((value == null) || (value.length() == 0))
    {
      if (lastHoveredLinkURL == null) {
        return 0;
      }
      lastHoveredLinkURL = null;
      StatusTextEvent statusText = new StatusTextEvent(browser);
      display = browser.getDisplay();
      widget = browser;
      text = "";
      for (int i = 0; i < statusTextListeners.length; i++) {
        statusTextListeners[i].changed(statusText);
      }
      return 0;
    }
    if (value.equals(lastHoveredLinkURL)) {
      return 0;
    }
    lastHoveredLinkURL = value;
    StatusTextEvent statusText = new StatusTextEvent(browser);
    display = browser.getDisplay();
    widget = browser;
    text = value;
    for (int i = 0; i < statusTextListeners.length; i++) {
      statusTextListeners[i].changed(statusText);
    }
    return 0;
  }
  
  int printFrame(int webView, int frame)
  {
    IWebFrame iwebFrame = new IWebFrame(frame);
    PRINTDLG pd = new PRINTDLG();
    lStructSize = PRINTDLG.sizeof;
    Flags = 256;
    if (!OS.PrintDlg(pd)) {
      return 0;
    }
    int printDC = hDC;
    
    int[] result = new int[1];
    int hr = iwebFrame.QueryInterface(WebKit_win32.IID_IWebFramePrivate, result);
    if ((hr != 0) || (result[0] == 0)) {
      return 0;
    }
    IWebFramePrivate privateFrame = new IWebFramePrivate(result[0]);
    privateFrame.setInPrintingMode(1, printDC);
    int[] count = new int[1];
    hr = privateFrame.getPrintedPageCount(printDC, count);
    if ((hr != 0) || (count[0] == 0))
    {
      privateFrame.Release();
      return 0;
    }
    int pageCount = count[0];
    String jobName = null;
    result[0] = 0;
    hr = iwebFrame.dataSource(result);
    if ((hr == 0) && (result[0] != 0))
    {
      IWebDataSource dataSource = new IWebDataSource(result[0]);
      result[0] = 0;
      hr = dataSource.pageTitle(result);
      dataSource.Release();
      if ((hr == 0) && (result[0] != 0))
      {
        jobName = WebKit.extractBSTR(result[0]);
        COM.SysFreeString(result[0]);
      }
    }
    DOCINFO di = new DOCINFO();
    cbSize = DOCINFO.sizeof;
    int hHeap = OS.GetProcessHeap();
    int lpszDocName = 0;
    if ((jobName != null) && (jobName.length() != 0))
    {
      TCHAR buffer = new TCHAR(0, jobName, true);
      int byteCount = buffer.length() * TCHAR.sizeof;
      lpszDocName = OS.HeapAlloc(hHeap, 8, byteCount);
      OS.MoveMemory(lpszDocName, buffer, byteCount);
      lpszDocName = lpszDocName;
    }
    int rc = OS.StartDoc(printDC, di);
    if (lpszDocName != 0) {
      OS.HeapFree(hHeap, 0, lpszDocName);
    }
    if (rc >= 0)
    {
      for (int i = 0; i < pageCount; i++)
      {
        OS.StartPage(printDC);
        privateFrame.spoolPages(printDC, i, i, null);
        OS.EndPage(printDC);
      }
      privateFrame.setInPrintingMode(0, printDC);
      OS.EndDoc(printDC);
    }
    privateFrame.Release();
    return 0;
  }
  
  int QueryInterface(int riid, int ppvObject)
  {
    if ((riid == 0) || (ppvObject == 0)) {
      return -2147024809;
    }
    GUID guid = new GUID();
    COM.MoveMemory(guid, riid, GUID.sizeof);
    if (COM.IsEqualGUID(guid, COM.IIDIUnknown))
    {
      COM.MoveMemory(ppvObject, new int[] { iWebUIDelegate.getAddress() }, OS.PTR_SIZEOF);
      new IUnknown(iWebUIDelegate.getAddress()).AddRef();
      return 0;
    }
    if (COM.IsEqualGUID(guid, WebKit_win32.IID_IWebUIDelegate))
    {
      COM.MoveMemory(ppvObject, new int[] { iWebUIDelegate.getAddress() }, OS.PTR_SIZEOF);
      new IUnknown(iWebUIDelegate.getAddress()).AddRef();
      return 0;
    }
    COM.MoveMemory(ppvObject, new int[1], OS.PTR_SIZEOF);
    return -2147467262;
  }
  
  int Release()
  {
    refCount -= 1;
    if (refCount == 0) {
      disposeCOMInterfaces();
    }
    return refCount;
  }
  
  int runBeforeUnloadConfirmPanelWithMessage(int sender, int message, int initiatedByFrame, int result)
  {
    if (!prompt) {
      return 0;
    }
    Shell parent = browser.getShell();
    String string = WebKit.extractBSTR(message);
    StringBuffer text = new StringBuffer(Compatibility.getMessage("SWT_OnBeforeUnload_Message1"));
    text.append("\n\n");
    text.append(string);
    text.append("\n\n");
    text.append(Compatibility.getMessage("SWT_OnBeforeUnload_Message2"));
    MessageBox box = new MessageBox(parent, 292);
    box.setMessage(text.toString());
    int[] response = new int[1];
    response[0] = (box.open() == 32 ? 1 : 0);
    OS.MoveMemory(result, response, 4);
    return 0;
  }
  
  int runJavaScriptAlertPanelWithMessage(int sender, int message)
  {
    String messageString = WebKit.extractBSTR(message);
    showAlertMessage("Javascript", messageString);
    return 0;
  }
  
  int runJavaScriptConfirmPanelWithMessage(int sender, int message, int result)
  {
    String messageString = WebKit.extractBSTR(message);
    int[] response = new int[1];
    response[0] = (showConfirmPanel("Javascript", messageString) == 32 ? 1 : 0);
    OS.MoveMemory(result, response, 4);
    return 0;
  }
  
  int runJavaScriptTextInputPanelWithPrompt(int sender, int message, int defaultText, int result)
  {
    String messageString = WebKit.extractBSTR(message);
    String defaultTextString = WebKit.extractBSTR(defaultText);
    String resultString = showTextPrompter("Javascript", messageString, defaultTextString);
    int[] response = new int[1];
    if (resultString != null) {
      response[0] = WebKit.createBSTR(resultString);
    }
    OS.MoveMemory(result, response, C.PTR_SIZEOF);
    return 0;
  }
  
  int runOpenPanelForFileButtonWithResultListener(int sender, int resultListener)
  {
    Shell parent = browser.getShell();
    FileDialog dialog = new FileDialog(parent, 0);
    String result = dialog.open();
    IWebOpenPanelResultListener listener = new IWebOpenPanelResultListener(resultListener);
    if (result == null) {
      listener.cancel();
    } else {
      listener.chooseFilename(WebKit.createBSTR(result));
    }
    return 0;
  }
  
  int setFrame(int sender, int frame)
  {
    RECT rect = new RECT();
    COM.MoveMemory(rect, frame, RECT.sizeof);
    
    location = browser.getDisplay().map(browser, null, left, top);
    int x = right - left;
    int y = bottom - top;
    if ((y < 0) || (x < 0) || ((x == 0) && (y == 0))) {
      return 0;
    }
    size = new Point(x, y);
    return 0;
  }
  
  int setMenuBarVisible(int sender, int visible)
  {
    menuBar = (visible == 1);
    return 0;
  }
  
  int setStatusBarVisible(int sender, int visible)
  {
    statusBar = (visible == 1);
    return 0;
  }
  
  int setStatusText(int sender, int text)
  {
    String statusText = WebKit.extractBSTR(text);
    if (statusText.length() == 0) {
      return 0;
    }
    StatusTextEvent statusTextEvent = new StatusTextEvent(browser);
    display = browser.getDisplay();
    widget = browser;
    text = statusText;
    StatusTextListener[] statusTextListeners = browser.webBrowser.statusTextListeners;
    for (int i = 0; i < statusTextListeners.length; i++) {
      statusTextListeners[i].changed(statusTextEvent);
    }
    return 0;
  }
  
  int setToolbarsVisible(int sender, int visible)
  {
    toolBar = (visible == 1);
    return 0;
  }
  
  void showAlertMessage(String title, String message)
  {
    Shell parent = browser.getShell();
    Shell dialog = new Shell(parent, 67680);
    GridLayout layout = new GridLayout(2, false);
    horizontalSpacing = 10;
    verticalSpacing = 20;
    marginWidth = (marginHeight = 10);
    dialog.setLayout(layout);
    dialog.setText(title);
    
    Label label = new Label(dialog, 0);
    Image image = dialog.getDisplay().getSystemImage(8);
    label.setImage(image);
    
    label = new Label(dialog, 64);
    label.setText(message);
    Monitor monitor = parent.getMonitor();
    int maxWidth = getBoundswidth * 2 / 3;
    int width = computeSize-1-1x;
    GridData data = new GridData(4, 16777216, true, false);
    widthHint = Math.min(width, maxWidth);
    label.setLayoutData(data);
    
    Button ok = new Button(dialog, 8);
    ok.setText(SWT.getMessage("SWT_OK"));
    width = computeSize-1-1x;
    GridData layoutData = new GridData();
    horizontalAlignment = 16777216;
    verticalAlignment = 16777216;
    horizontalSpan = 2;
    widthHint = Math.max(width, 75);
    ok.setLayoutData(layoutData);
    
    ok.addSelectionListener(new SelectionAdapter()
    {
      private final Shell val$dialog;
      
      public void widgetSelected(SelectionEvent e)
      {
        val$dialog.dispose();
      }
    });
    dialog.setDefaultButton(ok);
    dialog.pack();
    Rectangle parentSize = parent.getBounds();
    Rectangle dialogSize = dialog.getBounds();
    int x = getLocationx + (width - width) / 2;
    int y = getLocationy + (height - height) / 2;
    dialog.setLocation(x, y);
    dialog.open();
    Display display = browser.getDisplay();
    while (!dialog.isDisposed()) {
      if (!display.readAndDispatch()) {
        display.sleep();
      }
    }
  }
  
  int showConfirmPanel(String title, String message)
  {
    Shell parent = browser.getShell();
    Shell dialog = new Shell(parent, 67680);
    GridLayout layout = new GridLayout(2, false);
    horizontalSpacing = 10;
    verticalSpacing = 20;
    marginWidth = (marginHeight = 10);
    dialog.setLayout(layout);
    dialog.setText(title);
    
    Label label = new Label(dialog, 0);
    Image image = dialog.getDisplay().getSystemImage(4);
    label.setImage(image);
    label.setLayoutData(new GridData());
    
    label = new Label(dialog, 64);
    label.setText(message);
    Monitor monitor = parent.getMonitor();
    int maxWidth = getBoundswidth * 2 / 3;
    int width = computeSize-1-1x;
    GridData data = new GridData(4, 16777216, true, false);
    widthHint = Math.min(width, maxWidth);
    label.setLayoutData(data);
    
    Composite buttons = new Composite(dialog, 0);
    data = new GridData(16777216, 16777216, true, true, 2, 1);
    buttons.setLayoutData(data);
    buttons.setLayout(new GridLayout(2, true));
    
    Button ok = new Button(buttons, 8);
    ok.setText(SWT.getMessage("SWT_OK"));
    GridData layoutData = new GridData();
    horizontalAlignment = 16777216;
    verticalAlignment = 16777216;
    ok.setLayoutData(layoutData);
    
    Button cancel = new Button(buttons, 8);
    cancel.setText(SWT.getMessage("SWT_Cancel"));
    cancel.setLayoutData(layoutData);
    width = computeSize-1-1x;
    widthHint = Math.max(width, 75);
    
    int[] result = new int[1];
    ok.addSelectionListener(new SelectionAdapter()
    {
      private final int[] val$result;
      private final Shell val$dialog;
      
      public void widgetSelected(SelectionEvent e)
      {
        val$result[0] = 32;
        val$dialog.dispose();
      }
    });
    cancel.addSelectionListener(new SelectionAdapter()
    {
      private final int[] val$result;
      private final Shell val$dialog;
      
      public void widgetSelected(SelectionEvent e)
      {
        val$result[0] = 256;
        val$dialog.dispose();
      }
    });
    dialog.setDefaultButton(ok);
    dialog.pack();
    Rectangle parentSize = parent.getBounds();
    Rectangle dialogSize = dialog.getBounds();
    int x = getLocationx + (width - width) / 2;
    int y = getLocationy + (height - height) / 2;
    dialog.setLocation(x, y);
    dialog.open();
    Display display = browser.getDisplay();
    while (!dialog.isDisposed()) {
      if (!display.readAndDispatch()) {
        display.sleep();
      }
    }
    return result[0];
  }
  
  String showTextPrompter(String title, String message, String defaultText)
  {
    Shell parent = browser.getShell();
    Shell dialog = new Shell(parent, 67680);
    dialog.setLayout(new GridLayout());
    dialog.setText(title);
    
    Label label = new Label(dialog, 0);
    label.setLayoutData(new GridData(768));
    label.setText(message);
    
    Text textBox = new Text(dialog, 2052);
    GridData data = new GridData(768);
    widthHint = 300;
    textBox.setLayoutData(data);
    textBox.setText(defaultText);
    
    Composite buttons = new Composite(dialog, 0);
    buttons.setLayout(new GridLayout(2, true));
    buttons.setLayoutData(new GridData(64));
    Button ok = new Button(buttons, 8);
    ok.setText(SWT.getMessage("SWT_OK"));
    ok.setLayoutData(new GridData(768));
    
    String[] result = new String[1];
    ok.addSelectionListener(new SelectionAdapter()
    {
      private final String[] val$result;
      private final Text val$textBox;
      private final Shell val$dialog;
      
      public void widgetSelected(SelectionEvent e)
      {
        val$result[0] = val$textBox.getText();
        val$dialog.dispose();
      }
    });
    Button cancel = new Button(buttons, 8);
    cancel.setText(SWT.getMessage("SWT_Cancel"));
    cancel.setLayoutData(new GridData(768));
    cancel.addSelectionListener(new SelectionAdapter()
    {
      private final Shell val$dialog;
      
      public void widgetSelected(SelectionEvent e)
      {
        val$dialog.dispose();
      }
    });
    dialog.setDefaultButton(ok);
    dialog.pack();
    Rectangle parentSize = parent.getBounds();
    Rectangle dialogSize = dialog.getBounds();
    int x = getLocationx + (width - width) / 2;
    int y = getLocationy + (height - height) / 2;
    dialog.setLocation(x, y);
    dialog.open();
    Display display = browser.getDisplay();
    while (!dialog.isDisposed()) {
      if (!display.readAndDispatch()) {
        display.sleep();
      }
    }
    return result[0];
  }
  
  int takeFocus(int sender, int forward)
  {
    int traveralCode = forward == 0 ? 8 : 16;
    browser.webBrowser).traverseOut = true;
    browser.traverse(traveralCode);
    return 0;
  }
  
  int webViewClose(int sender)
  {
    WindowEvent newEvent = new WindowEvent(browser);
    display = browser.getDisplay();
    widget = browser;
    CloseWindowListener[] closeWindowListeners = browser.webBrowser.closeWindowListeners;
    for (int i = 0; i < closeWindowListeners.length; i++) {
      closeWindowListeners[i].close(newEvent);
    }
    browser.dispose();
    return 0;
  }
  
  int webViewFrame(int sender, int frame)
  {
    RECT rect = new RECT();
    OS.MoveMemory(frame, rect, RECT.sizeof);
    return 0;
  }
  
  int webViewShow(int sender)
  {
    WindowEvent newEvent = new WindowEvent(browser);
    display = browser.getDisplay();
    widget = browser;
    if (location != null) {
      location = location;
    }
    if (size != null) {
      size = size;
    }
    addressBar = toolBar;
    menuBar = menuBar;
    statusBar = statusBar;
    toolBar = toolBar;
    VisibilityWindowListener[] visibilityWindowListeners = browser.webBrowser.visibilityWindowListeners;
    for (int i = 0; i < visibilityWindowListeners.length; i++) {
      visibilityWindowListeners[i].show(newEvent);
    }
    location = null;
    size = null;
    return 0;
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WebUIDelegate
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.internal.mozilla.XPCOMObject;

class WindowCreator2$1
  extends XPCOMObject
{
  final WindowCreator2 this$0;
  
  WindowCreator2$1(WindowCreator2 paramWindowCreator2, int[] $anonymous0)
  {
    super($anonymous0);this$0 = paramWindowCreator2;
  }
  
  public int method0(int[] args)
  {
    return this$0.QueryInterface(args[0], args[1]);
  }
  
  public int method1(int[] args)
  {
    return this$0.AddRef();
  }
  
  public int method2(int[] args)
  {
    return this$0.Release();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WindowCreator2.1
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.internal.mozilla.XPCOMObject;

class WindowCreator2$2
  extends XPCOMObject
{
  final WindowCreator2 this$0;
  
  WindowCreator2$2(WindowCreator2 paramWindowCreator2, int[] $anonymous0)
  {
    super($anonymous0);this$0 = paramWindowCreator2;
  }
  
  public int method0(int[] args)
  {
    return this$0.QueryInterface(args[0], args[1]);
  }
  
  public int method1(int[] args)
  {
    return this$0.AddRef();
  }
  
  public int method2(int[] args)
  {
    return this$0.Release();
  }
  
  public int method3(int[] args)
  {
    return this$0.CreateChromeWindow(args[0], args[1], args[2]);
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WindowCreator2.2
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.internal.mozilla.XPCOMObject;

class WindowCreator2$3
  extends XPCOMObject
{
  final WindowCreator2 this$0;
  
  WindowCreator2$3(WindowCreator2 paramWindowCreator2, int[] $anonymous0)
  {
    super($anonymous0);this$0 = paramWindowCreator2;
  }
  
  public int method0(int[] args)
  {
    return this$0.QueryInterface(args[0], args[1]);
  }
  
  public int method1(int[] args)
  {
    return this$0.AddRef();
  }
  
  public int method2(int[] args)
  {
    return this$0.Release();
  }
  
  public int method3(int[] args)
  {
    return this$0.CreateChromeWindow(args[0], args[1], args[2]);
  }
  
  public int method4(int[] args)
  {
    return this$0.CreateChromeWindow2(args[0], args[1], args[2], args[3], args[4], args[5]);
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WindowCreator2.3
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.graphics.Point;
import org.eclipse.swt.widgets.Shell;

class WindowCreator2$4
  implements VisibilityWindowListener
{
  final WindowCreator2 this$0;
  private final Shell val$shell;
  
  WindowCreator2$4(WindowCreator2 paramWindowCreator2, Shell paramShell)
  {
    this$0 = paramWindowCreator2;val$shell = paramShell;
  }
  
  public void hide(WindowEvent event) {}
  
  public void show(WindowEvent event)
  {
    if (location != null) {
      val$shell.setLocation(location);
    }
    if (size != null)
    {
      Point size = size;
      val$shell.setSize(val$shell.computeSize(x, y));
    }
    val$shell.open();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WindowCreator2.4
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.widgets.Shell;

class WindowCreator2$5
  implements CloseWindowListener
{
  final WindowCreator2 this$0;
  private final Shell val$shell;
  
  WindowCreator2$5(WindowCreator2 paramWindowCreator2, Shell paramShell)
  {
    this$0 = paramWindowCreator2;val$shell = paramShell;
  }
  
  public void close(WindowEvent event)
  {
    val$shell.close();
  }
}

/* Location:
 * Qualified Name:     org.eclipse.swt.browser.WindowCreator2.5
 * Java Class Version: 1.2 (46.0)
 * JD-Core Version:    0.7.1
 */
package org.eclipse.swt.browser;

import org.eclipse.swt.graphics.Point;
import org.eclipse.swt.internal.C;
import org.eclipse.swt.internal.mozilla.XPCOM;
import org.eclipse.swt.internal.mozilla.XPCOMObject;
import org.eclipse.swt.internal.mozilla.nsIBaseWindow;
import org.eclipse.swt.internal.mozilla.nsID;
import org.eclipse.swt.internal.mozilla.nsISupports;
import org.eclipse.swt.internal.mozilla.nsIURI;
import org.eclipse.swt.internal.mozilla.nsIWebBrowser;
import org.eclipse.swt.internal.mozilla.nsIWebBrowserChrome;
import org.eclipse.swt.internal.mozilla.nsIWindowCreator;
import org.eclipse.swt.internal.mozilla.nsIWindowCreator2;
import org.eclipse.swt.layout.FillLayout;
import org.eclipse.swt.widgets.Shel
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146

Further reading...

For more information on Java 1.5 Tiger, you may find Java 1.5 Tiger, A developer's Notebook by D. Flanagan and B. McLaughlin from O'Reilly of interest.

New!JAR listings


Copyright 2006-2017. Infinite Loop Ltd