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

com.extjs.gxt.ui.client.widget.ComponentComposite Maven / Gradle / Ivy

/*
 * Ext GWT - Ext for GWT
 * Copyright(c) 2007-2009, Ext JS, LLC.
 * [email protected]
 * 
 * http://extjs.com/license
 */
package com.extjs.gxt.ui.client.widget;

import com.google.gwt.user.client.DOM;
import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.Widget;

/**
 * A GWT Composite subclass that handles GXT lazy rendering. This
 * class is intended to only be used when working with the GWT Composite widget.
 * The GXT {@link Composite} us preferred as it is a GXT Component subclass.
 * 
 * 

* The class should be used when wrapping a component in a GWT Composite class. * * @see com.extjs.gxt.ui.client.widget.Composite * @see WidgetComponent */ public class ComponentComposite extends Composite { protected Component component; @Override protected void initWidget(final Widget widget) { if (widget instanceof Component) { component = (Component) widget; if (!component.isRendered()) { component.render(DOM.createDiv()); } } super.initWidget(widget); } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy