添加左侧面板实现
This commit is contained in:
@@ -61,6 +61,7 @@ public class MainActivity extends MvpActivity< MainView, MainPresenter > impleme
|
||||
protected View mEntrance;
|
||||
protected FrameLayout mFloatingLayout;
|
||||
protected FrameLayout mCoverUpLayout;
|
||||
protected FrameLayout mLeftPanelLayout;
|
||||
protected View mLeftShadowFrame;
|
||||
private boolean mIsHomeKeyDown = false;
|
||||
|
||||
@@ -80,6 +81,7 @@ public class MainActivity extends MvpActivity< MainView, MainPresenter > impleme
|
||||
mFloatingLayout = findViewById( R.id.module_main_id_floating_view );
|
||||
mLeftShadowFrame = findViewById( R.id.module_main_id_map_left_shadow_frame );
|
||||
mCoverUpLayout = findViewById( R.id.module_main_id_cover_up );
|
||||
mLeftPanelLayout = findViewById(R.id.module_main_id_left_panel_fragment_container);
|
||||
|
||||
// 避免事件穿透导致地图被滑动
|
||||
mLeftShadowFrame.setOnClickListener( view -> {
|
||||
@@ -183,6 +185,7 @@ public class MainActivity extends MvpActivity< MainView, MainPresenter > impleme
|
||||
// MogoModulesManager.getInstance().loadExtensionsModule( R.id.module_main_id_header_fragment_container );
|
||||
MogoModulesManager.getInstance().loadEntrancesModule( R.id.module_main_id_entrance_fragment_container );
|
||||
MogoModulesManager.getInstance().loadEventPanelModule(R.id.module_main_id_event_panel_fragment_container);
|
||||
MogoModulesManager.getInstance().loadLeftPanelModule(R.id.module_main_id_left_panel_fragment_container);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -65,4 +65,10 @@ public interface MogoModulesHandler {
|
||||
* @param containerId
|
||||
*/
|
||||
void loadEventPanelModule(int containerId);
|
||||
|
||||
/**
|
||||
* 加载左侧面板
|
||||
* @param containerId
|
||||
*/
|
||||
void loadLeftPanelModule(int containerId);
|
||||
}
|
||||
|
||||
@@ -139,6 +139,14 @@ public class MogoModulesManager implements MogoModulesHandler {
|
||||
addFragment( provider, containerId );
|
||||
}
|
||||
|
||||
@Override
|
||||
public void loadLeftPanelModule(int containerId) {
|
||||
IMogoModuleProvider provider = ( IMogoModuleProvider ) ARouter.getInstance()
|
||||
.build(MogoServicePaths.PATH_LEFT_PANEL)
|
||||
.navigation( getContext() );
|
||||
addFragment( provider, containerId );
|
||||
}
|
||||
|
||||
@Override
|
||||
public void loadBaseModule() {
|
||||
List< MogoModule > baseModules = MogoModulePaths.getBaseModules();
|
||||
|
||||
Reference in New Issue
Block a user