All Downloads are FREE. Search and download functionalities are using the official Maven repository.

at.spardat.xma.page.DialogEventAdapter Maven / Gradle / Ivy

/*******************************************************************************
 * Copyright (c) 2003, 2007 s IT Solutions AT Spardat GmbH .
 * 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
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     s IT Solutions AT Spardat GmbH - initial API and implementation
 *******************************************************************************/

package at.spardat.xma.page;

import org.eclipse.swt.events.*;

/**
 * Adapter of Shell-Events for DialogPage.
 * It forwards all supported Shell-Events to the DialogPage.
 * It is used to prevent the event-Methods from appearing in the public interface
 * of DialogPage.
 *   
 * @author s2877
 */
class DialogEventAdapter extends ShellAdapter implements DisposeListener {
    
    /** the DialogPage this Adapter belongs to */
    DialogPage page;

    /**
     * Constructor for DialogEventAdapter.
     * 
     * @param page the DialogPage this Adapter belongs to
     */
    public DialogEventAdapter(DialogPage page) {
        this.page=page;
    }

    /**
     * This Method is called when the shell is closed.
     * 
     * @param event the Event that happened.
     */
    public void shellClosed(ShellEvent event) {
        page.shellClosed(event);
    }
    
    /**
     * This Method is called when the shell is disposed.
     * 
     * @param event the Event that happened.
     */
    public void widgetDisposed(DisposeEvent event) {
        page.widgetDisposed(event);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy