Package org.eclipse.swt.browser

Examples of org.eclipse.swt.browser.LocationListener


    /**
     *
     * @param name
     */
    public void setListener(String name) {
        LocationListener blah = null;
        if(name != null) {
            try {
                blah = (LocationListener)Class.forName(name).newInstance();
            } catch (InstantiationException e) {
                //
View Full Code Here


        IWizardPage ipage = getContainer().getCurrentPage();
        String name = null;
        URL url = null;
        //String viewName = null;
        ImageDescriptor image = null;
        LocationListener listen = null;
        if(ipage instanceof BrowserSelectionPage) {
            BrowserSelectionPage page = (BrowserSelectionPage)ipage;
            listen = page.getListener();
            url = page.getUrl();
            image = page.getIconDescriptor();
View Full Code Here

     *
     * @return singleton LocationListener
     */
    public LocationListener getListener() {
        if(this.locListen == null) {
            this.locListen = new LocationListener() {
                public void changing(LocationEvent event) {
                    String url = event.location;
                    // Should be part of ServiceExtension extension point.
                    if(url.toLowerCase().indexOf("=getcapabilities") != -1 //$NON-NLS-1$
                            || url.toLowerCase().indexOf("jdbc:postgis://") != -1 //$NON-NLS-1$
View Full Code Here

    Browser browser = new Browser(parent, SWT.BORDER);
    browser.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true))
   
    browser.setText(_data);
   
    browser.addLocationListener(new LocationListener() {
      public void changed(LocationEvent event) {
      }
      public void changing(LocationEvent event) {
        // Cancel default link processing.
        event.doit = false;
View Full Code Here

 
  private void initializeBrowser() {
    _browser = new Browser(_parent, SWT.NONE);          
    setLocation("index.html"); //$NON-NLS-1$
   
    _browser.addLocationListener(new LocationListener() {
      public void changed(LocationEvent event) {
        updateActionState();
      }
      public void changing(LocationEvent event) {
        if (!event.location.equals("about:blank")) { //$NON-NLS-1$
View Full Code Here

      public void widgetDefaultSelected(SelectionEvent e) {
        browser.setUrl(ts.getText());
      }
    });
    ts.setText(br.uri);
    browser.addLocationListener(new LocationListener() {

      public void changing(LocationEvent event) {

      }
View Full Code Here

      }
    });

    // Tie the location text box to the browser's location.
    //
    browser.addLocationListener(new LocationListener() {

      public void changed(LocationEvent evt) {
        if (evt.top) {
          setLocationText(evt.location);
        }
View Full Code Here

      browser.setText(html);
    } else if (url != null) {
      browser.setUrl(url.toString());
    }

    browser.addLocationListener(new LocationListener() {
      public void changed(LocationEvent event) {
      }

      public void changing(LocationEvent event) {
        event.doit = false;
View Full Code Here

           public void handleEvent(Event event) {
           browser.forward();
           }
        });
       
        LocationListener locationListener = new LocationListener() {
            public void changed(LocationEvent event) {
                  Browser browser = (Browser)event.widget;
                  back.setEnabled(browser.isBackEnabled());
                  forward.setEnabled(browser.isForwardEnabled());
               }
View Full Code Here

           public void handleEvent(Event event) {
           browser.forward();
           }
        });
       
        LocationListener locationListener = new LocationListener() {
            public void changed(LocationEvent event) {
                  Browser browser = (Browser)event.widget;
                  back.setEnabled(browser.isBackEnabled());
                  forward.setEnabled(browser.isForwardEnabled());
               }
View Full Code Here

TOP

Related Classes of org.eclipse.swt.browser.LocationListener

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.