Search in sources :

Example 11 with Animation

use of com.google.gwt.animation.client.Animation in project kie-wb-common by kiegroup.

the class ShowcaseEntryPoint method hideLoadingPopup.

// Fade out the "Loading application" pop-up
private void hideLoadingPopup() {
    final Element e = RootPanel.get("loading").getElement();
    new Animation() {

        @Override
        protected void onUpdate(double progress) {
            e.getStyle().setOpacity(1.0 - progress);
        }

        @Override
        protected void onComplete() {
            e.getStyle().setVisibility(Style.Visibility.HIDDEN);
        }
    }.run(500);
}
Also used : Element(com.google.gwt.dom.client.Element) Animation(com.google.gwt.animation.client.Animation)

Example 12 with Animation

use of com.google.gwt.animation.client.Animation in project ovirt-engine by oVirt.

the class AnimatedVerticalPanel method addFadeIn.

public void addFadeIn(Widget w) {
    final Style widgetStyle = w.getElement().getStyle();
    widgetStyle.setOpacity(0);
    add(w);
    new Animation() {

        @Override
        protected void onUpdate(double progress) {
            widgetStyle.setOpacity(progress);
        }
    }.run(ANIM_DELAY);
}
Also used : Style(com.google.gwt.dom.client.Style) Animation(com.google.gwt.animation.client.Animation)

Example 13 with Animation

use of com.google.gwt.animation.client.Animation in project webprotege by protegeproject.

the class TagCriteriaListViewImpl method addTagCriteriaViewContainer.

@Override
public void addTagCriteriaViewContainer(@Nonnull TagCriteriaViewContainer container, boolean scrollIntoView, boolean animate) {
    tagCriteriaListContainer.add(container);
    if (scrollIntoView) {
        addButton.getElement().scrollIntoView();
    }
    if (animate) {
        Element element = container.asWidget().getElement();
        Style style = element.getStyle();
        style.setOpacity(0);
        Animation animation = new Animation() {

            @Override
            protected void onUpdate(double progress) {
                style.setOpacity(progress);
            }
        };
        animation.run(ANIMATION_DURATION_MS);
    }
}
Also used : Element(com.google.gwt.dom.client.Element) Style(com.google.gwt.dom.client.Style) Animation(com.google.gwt.animation.client.Animation)

Example 14 with Animation

use of com.google.gwt.animation.client.Animation in project webprotege by protegeproject.

the class ModalViewImpl method hide.

@Override
public void hide() {
    Animation animation = new Animation() {

        @Override
        protected void onUpdate(double progress) {
            getElement().getStyle().setOpacity(1 - progress);
            if (progress == 1.0) {
                removeFromParent();
                getElement().getStyle().setOpacity(1);
            }
        }
    };
    animation.run(300);
}
Also used : Animation(com.google.gwt.animation.client.Animation)

Example 15 with Animation

use of com.google.gwt.animation.client.Animation in project appformer by kiegroup.

the class ShowcaseEntryPoint method hideLoadingPopup.

// Fade out the "Loading application" pop-up
private void hideLoadingPopup() {
    final Element e = RootPanel.get("loading").getElement();
    new Animation() {

        @Override
        protected void onUpdate(double progress) {
            e.getStyle().setOpacity(1.0 - progress);
        }

        @Override
        protected void onComplete() {
            e.getStyle().setVisibility(Style.Visibility.HIDDEN);
        }
    }.run(500);
}
Also used : Element(com.google.gwt.dom.client.Element) Animation(com.google.gwt.animation.client.Animation)

Aggregations

Animation (com.google.gwt.animation.client.Animation)16 Element (com.google.gwt.dom.client.Element)8 Style (com.google.gwt.dom.client.Style)2 Timer (com.google.gwt.user.client.Timer)2 Point (org.rstudio.core.client.Point)2 ScheduledCommand (com.google.gwt.core.client.Scheduler.ScheduledCommand)1 FormElement (com.google.gwt.dom.client.FormElement)1 InputElement (com.google.gwt.dom.client.InputElement)1 Node (com.google.gwt.dom.client.Node)1 ClickEvent (com.google.gwt.event.dom.client.ClickEvent)1 ClickHandler (com.google.gwt.event.dom.client.ClickHandler)1 Element (com.google.gwt.user.client.Element)1 SplitterResizedEvent (com.google.gwt.user.client.ui.SplitterResizedEvent)1 AfterInitialization (org.jboss.errai.ioc.client.api.AfterInitialization)1 KeyboardShortcut (org.rstudio.core.client.command.KeyboardShortcut)1 NodePredicate (org.rstudio.core.client.dom.DomUtils.NodePredicate)1 ImageResource2x (org.rstudio.core.client.resources.ImageResource2x)1 RSConnectPublishButton (org.rstudio.studio.client.rsconnect.ui.RSConnectPublishButton)1 EditingTargetToolbar (org.rstudio.studio.client.workbench.views.source.editors.EditingTargetToolbar)1