MCPcopy Create free account
hub / github.com/cinit/TMoe / BaseProxyFragment

Class BaseProxyFragment

app/src/main/java/cc/ioctl/tmoe/base/BaseProxyFragment.java:24–311  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

22import cc.ioctl.tmoe.ui.Theme;
23
24public abstract class BaseProxyFragment {
25
26 private Bundle mArgs;
27 private boolean mIsPaused = true;
28 private final ProxyFragmentRttiHandler mProxyRttiHandler;
29
30 protected BaseProxyFragment() {
31 this(null);
32 }
33
34 protected BaseProxyFragment(@Nullable Bundle args) {
35 mArgs = args;
36 mProxyRttiHandler = new ProxyFragmentRttiHandler(this);
37 }
38
39 public ProxyFragmentRttiHandler getProxyRttiHandler() {
40 return mProxyRttiHandler;
41 }
42
43 public Object getProxyObject() {
44 return mProxyRttiHandler.getProxyInstance();
45 }
46
47 public interface ActionBarWrapper {
48 void setBackButtonImage(int resource);
49
50 @Nullable
51 ImageView getBackButton();
52
53 void setActionBarMenuOnItemClick(View.OnClickListener listener);
54
55 void setTitle(CharSequence value);
56
57 String getTitle();
58
59 String getSubtitle();
60
61 void setSubtitle(CharSequence value);
62 }
63
64 @Nullable
65 public ViewGroup getActionBar() {
66 return mProxyRttiHandler.getActionBar();
67 }
68
69 @Nullable
70 public ActionBarWrapper getActionBarWrapper() {
71 return mProxyRttiHandler.getActionBarWrapper();
72 }
73
74 public abstract View onCreateView(@NonNull Context context);
75
76 public Bundle getArguments() {
77 return mArgs;
78 }
79
80 public boolean isSwipeBackEnabled(MotionEvent event) {
81 return true;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected