|
|
@ -29,6 +29,7 @@ import com.fr.design.mainframe.guide.tip.GuideTip; |
|
|
|
import com.fr.design.mainframe.share.ui.block.OnlineWidgetPackageBlock; |
|
|
|
import com.fr.design.mainframe.share.ui.block.OnlineWidgetPackageBlock; |
|
|
|
import com.fr.design.mainframe.share.ui.online.OnlineWidgetRepoPane; |
|
|
|
import com.fr.design.mainframe.share.ui.online.OnlineWidgetRepoPane; |
|
|
|
import com.fr.design.mainframe.share.ui.online.OnlineWidgetTabPane; |
|
|
|
import com.fr.design.mainframe.share.ui.online.OnlineWidgetTabPane; |
|
|
|
|
|
|
|
import com.fr.design.mainframe.share.ui.online.widgetpackage.OnlineWidgetPackagesShowPane; |
|
|
|
import com.fr.design.mainframe.share.util.DownloadUtils; |
|
|
|
import com.fr.design.mainframe.share.util.DownloadUtils; |
|
|
|
import com.fr.design.mainframe.share.util.OnlineShopUtils; |
|
|
|
import com.fr.design.mainframe.share.util.OnlineShopUtils; |
|
|
|
import com.fr.design.utils.ComponentUtils; |
|
|
|
import com.fr.design.utils.ComponentUtils; |
|
|
@ -102,22 +103,23 @@ public class DownloadComponentPackageGuide { |
|
|
|
EastRegionContainerPane.getInstance().showContainer(); |
|
|
|
EastRegionContainerPane.getInstance().showContainer(); |
|
|
|
EastRegionContainerPane.getInstance().switchTabTo(EastRegionContainerPane.KEY_WIDGET_SETTINGS); |
|
|
|
EastRegionContainerPane.getInstance().switchTabTo(EastRegionContainerPane.KEY_WIDGET_SETTINGS); |
|
|
|
OnlineWidgetRepoPane onlineWidgetRepoPane = OnlineWidgetRepoPane.getInstance(); |
|
|
|
OnlineWidgetRepoPane onlineWidgetRepoPane = OnlineWidgetRepoPane.getInstance(); |
|
|
|
onlineWidgetRepoPane.setContent(); |
|
|
|
Component onlineWidgetPackagesShowPane = ComponentUtils.findComponentByClass(onlineWidgetRepoPane, OnlineWidgetPackagesShowPane.class); |
|
|
|
OnlineWidgetTabPane tabPane = (OnlineWidgetTabPane) ComponentUtils.findComponentByClass(onlineWidgetRepoPane, OnlineWidgetTabPane.class); |
|
|
|
if (onlineWidgetPackagesShowPane != null) { |
|
|
|
UITabGroup tabGroup = (UITabGroup) ComponentUtils.findComponentByClass(tabPane, UITabGroup.class); |
|
|
|
|
|
|
|
JPanel centerPane = (JPanel) tabPane.getComponent(1); |
|
|
|
|
|
|
|
if (centerPane.getComponentCount() > 0) { |
|
|
|
|
|
|
|
GuideManager.getInstance().getCurrentGuide().start(); |
|
|
|
GuideManager.getInstance().getCurrentGuide().start(); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
|
|
|
|
onlineWidgetRepoPane.setContent(); |
|
|
|
|
|
|
|
OnlineWidgetTabPane tabPane = (OnlineWidgetTabPane) ComponentUtils.findComponentByClass(onlineWidgetRepoPane, OnlineWidgetTabPane.class); |
|
|
|
|
|
|
|
JPanel centerPane = (JPanel) tabPane.getComponent(1); |
|
|
|
centerPane.addContainerListener(new ContainerAdapter() { |
|
|
|
centerPane.addContainerListener(new ContainerAdapter() { |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public void componentAdded(ContainerEvent e) { |
|
|
|
public void componentAdded(ContainerEvent e) { |
|
|
|
GuideManager.getInstance().getCurrentGuide().start(); |
|
|
|
if (e.getChild() instanceof OnlineWidgetPackagesShowPane) { |
|
|
|
|
|
|
|
GuideManager.getInstance().getCurrentGuide().start(); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
} |
|
|
|
} |
|
|
|
tabGroup.setSelectedIndex(1); |
|
|
|
switch2OnlinePackageBlock(); |
|
|
|
tabGroup.tabChanged(1); |
|
|
|
|
|
|
|
} else { |
|
|
|
} else { |
|
|
|
GuideCreateUtils.showNoNetworkAlert(); |
|
|
|
GuideCreateUtils.showNoNetworkAlert(); |
|
|
|
GuideManager.getInstance().getCurrentGuide().terminate(); |
|
|
|
GuideManager.getInstance().getCurrentGuide().terminate(); |
|
|
@ -168,7 +170,7 @@ public class DownloadComponentPackageGuide { |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public boolean onComplete() { |
|
|
|
public boolean onComplete() { |
|
|
|
FormWidgetDetailPane.getInstance().swich2Online(); |
|
|
|
FormWidgetDetailPane.getInstance().switch2Online(); |
|
|
|
return true; |
|
|
|
return true; |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
@ -270,7 +272,7 @@ public class DownloadComponentPackageGuide { |
|
|
|
public boolean prepared() { |
|
|
|
public boolean prepared() { |
|
|
|
Component target = ComponentUtils.findComponentByClass(themeConfirmDialog.getContentPane(), UIButton.class); |
|
|
|
Component target = ComponentUtils.findComponentByClass(themeConfirmDialog.getContentPane(), UIButton.class); |
|
|
|
scene.addClickTarget(target, ClickScene.ClickType.LEFT); |
|
|
|
scene.addClickTarget(target, ClickScene.ClickType.LEFT); |
|
|
|
scene.addBubbleTip(Toolkit.i18nText("Fine-Design_Guide_Scene_Base_Tip_Click_Confirm"), GuideTip.Direction.BOTTOM); |
|
|
|
scene.addBubbleTip(Toolkit.i18nText("Fine-Design_Guide_Scene_Base_Tip_Click_Confirm", Toolkit.i18nText("Fine-Design_Basic_Confirm")), GuideTip.Direction.BOTTOM); |
|
|
|
return super.prepared(); |
|
|
|
return super.prepared(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -298,4 +300,11 @@ public class DownloadComponentPackageGuide { |
|
|
|
themeConfirmDialog.dispose(); |
|
|
|
themeConfirmDialog.dispose(); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static void switch2OnlinePackageBlock() { |
|
|
|
|
|
|
|
OnlineWidgetTabPane tabPane = (OnlineWidgetTabPane) ComponentUtils.findComponentByClass(OnlineWidgetRepoPane.getInstance(), OnlineWidgetTabPane.class); |
|
|
|
|
|
|
|
UITabGroup tabGroup = (UITabGroup) ComponentUtils.findComponentByClass(tabPane, UITabGroup.class); |
|
|
|
|
|
|
|
tabGroup.setSelectedIndex(1); |
|
|
|
|
|
|
|
tabGroup.tabChanged(1); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|