-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update UI; BaseIdleScreen不再含有任何UI,具体项目使用自己的BaseIdleXXXScreen
- Loading branch information
Showing
36 changed files
with
265 additions
and
255 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 0 additions & 6 deletions
6
...-game/core/src/main/java/hundun/gdxgame/idledemo/ui/achievement/OneAchievementNodeVM.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 0 additions & 2 deletions
2
...Demo-game/core/src/main/java/hundun/gdxgame/idledemo/ui/shared/BaseCellDetailBoardVM.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 0 additions & 5 deletions
5
IdleDemo-game/core/src/main/java/hundun/gdxgame/idledemo/ui/shared/BaseCellDetailNodeVM.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
74 changes: 74 additions & 0 deletions
74
IdleDemo-game/core/src/main/java/hundun/gdxgame/idledemo/ui/shared/BaseIdleDemoScreen.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
package hundun.gdxgame.idledemo.ui.shared; | ||
|
||
import com.badlogic.gdx.scenes.scene2d.ui.Table; | ||
import hundun.gdxgame.idledemo.DemoIdleGame; | ||
import hundun.gdxgame.idledemo.DemoIdleGame; | ||
import hundun.gdxgame.idledemo.logic.RootSaveData; | ||
import hundun.gdxgame.idleshare.core.starter.ui.component.BackgroundImageBox; | ||
import hundun.gdxgame.idleshare.core.starter.ui.component.GameAreaControlBoard; | ||
import hundun.gdxgame.idleshare.core.starter.ui.component.StarterStorageInfoBoard; | ||
import hundun.gdxgame.idleshare.core.starter.ui.screen.play.BaseIdleScreen; | ||
import hundun.gdxgame.idleshare.core.starter.ui.screen.play.PlayScreenLayoutConst; | ||
|
||
public abstract class BaseIdleDemoScreen extends BaseIdleScreen<DemoIdleGame, RootSaveData> { | ||
|
||
protected StarterStorageInfoBoard<DemoIdleGame, RootSaveData> storageInfoTable; | ||
|
||
protected BackgroundImageBox<DemoIdleGame, RootSaveData> backgroundImageBox; | ||
protected GameAreaControlBoard<DemoIdleGame, RootSaveData> gameAreaControlBoard; | ||
|
||
protected Table leftSideGroup; | ||
protected Table middleGroup; | ||
|
||
protected static int UI_ROOT_TABLE_COLSPAN_SIZE = 3; | ||
|
||
public BaseIdleDemoScreen(DemoIdleGame game, String screenId, PlayScreenLayoutConst layoutConst) { | ||
super(game, screenId, layoutConst); | ||
} | ||
|
||
@Override | ||
protected void lazyInitLogicContext() { | ||
logicFrameListeners.add(game.getIdleGameplayExport()); | ||
|
||
gameAreaChangeListeners.add(backgroundImageBox); | ||
gameAreaChangeListeners.add(gameAreaControlBoard); | ||
|
||
gameAreaControlBoard.lazyInit(game.getControlBoardScreenIds()); | ||
|
||
this.getGame().getIdleGameplayExport().getGameplayContext().getEventManager().registerListener(this); | ||
this.getGame().getIdleGameplayExport().getGameplayContext().getEventManager().registerListener(storageInfoTable); | ||
} | ||
|
||
@Override | ||
protected void lazyInitUiRootContext() { | ||
|
||
storageInfoTable = new StarterStorageInfoBoard<>(this); | ||
uiRootTable.add(storageInfoTable) | ||
.height(layoutConst.STORAGE_BOARD_BORDER_HEIGHT) | ||
.fill() | ||
.colspan(UI_ROOT_TABLE_COLSPAN_SIZE) | ||
.row(); | ||
|
||
leftSideGroup = new Table(); | ||
uiRootTable.add(leftSideGroup) | ||
.growY(); | ||
|
||
middleGroup = new Table(); | ||
uiRootTable.add(middleGroup).grow(); | ||
|
||
gameAreaControlBoard = new GameAreaControlBoard<>(this); | ||
gameAreaControlBoard.top(); | ||
uiRootTable.add(gameAreaControlBoard) | ||
.growY() | ||
.row(); | ||
|
||
} | ||
|
||
@Override | ||
protected void lazyInitBackUiAndPopupUiContent() { | ||
|
||
this.backgroundImageBox = new BackgroundImageBox<>(this); | ||
backUiStage.addActor(backgroundImageBox); | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 0 additions & 6 deletions
6
...-game/core/src/main/java/hundun/gdxgame/idledemo/ui/achievement/OneAchievementNodeVM.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.