FragmentController.java
9.87 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
package android.support.v4.app;
import android.content.Context;
import android.content.res.Configuration;
import android.os.Parcelable;
import android.support.annotation.Nullable;
import android.support.v4.util.SimpleArrayMap;
import android.support.v4.util.SparseArrayCompat;
import android.util.AttributeSet;
import android.util.Log;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import cn;
import cq;
import cq.a;
import java.io.FileDescriptor;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.List;
public class FragmentController
{
private final FragmentHostCallback<?> a;
private FragmentController(FragmentHostCallback<?> paramFragmentHostCallback)
{
this.a = paramFragmentHostCallback;
}
public static final FragmentController createController(FragmentHostCallback<?> paramFragmentHostCallback)
{
return new FragmentController(paramFragmentHostCallback);
}
public void attachHost(Fragment paramFragment)
{
this.a.f.a(this.a, this.a, paramFragment);
}
public void dispatchActivityCreated()
{
this.a.f.g();
}
public void dispatchConfigurationChanged(Configuration paramConfiguration)
{
this.a.f.a(paramConfiguration);
}
public boolean dispatchContextItemSelected(MenuItem paramMenuItem)
{
return this.a.f.b(paramMenuItem);
}
public void dispatchCreate()
{
this.a.f.f();
}
public boolean dispatchCreateOptionsMenu(Menu paramMenu, MenuInflater paramMenuInflater)
{
return this.a.f.a(paramMenu, paramMenuInflater);
}
public void dispatchDestroy()
{
this.a.f.k();
}
public void dispatchDestroyView()
{
this.a.f.a(1, false);
}
public void dispatchLowMemory()
{
this.a.f.l();
}
public void dispatchMultiWindowModeChanged(boolean paramBoolean)
{
this.a.f.a(paramBoolean);
}
public boolean dispatchOptionsItemSelected(MenuItem paramMenuItem)
{
return this.a.f.a(paramMenuItem);
}
public void dispatchOptionsMenuClosed(Menu paramMenu)
{
this.a.f.b(paramMenu);
}
public void dispatchPause()
{
this.a.f.a(4, false);
}
public void dispatchPictureInPictureModeChanged(boolean paramBoolean)
{
this.a.f.b(paramBoolean);
}
public boolean dispatchPrepareOptionsMenu(Menu paramMenu)
{
return this.a.f.a(paramMenu);
}
public void dispatchReallyStop()
{
this.a.f.a(2, false);
}
public void dispatchResume()
{
this.a.f.i();
}
public void dispatchStart()
{
this.a.f.h();
}
public void dispatchStop()
{
this.a.f.j();
}
public void doLoaderDestroy()
{
FragmentHostCallback localFragmentHostCallback = this.a;
if (localFragmentHostCallback.i != null) {
localFragmentHostCallback.i.f();
}
}
public void doLoaderRetain()
{
FragmentHostCallback localFragmentHostCallback = this.a;
if (localFragmentHostCallback.i != null) {
localFragmentHostCallback.i.c();
}
}
public void doLoaderStart()
{
FragmentHostCallback localFragmentHostCallback = this.a;
if (!localFragmentHostCallback.k)
{
localFragmentHostCallback.k = true;
if (localFragmentHostCallback.i == null) {
break label37;
}
localFragmentHostCallback.i.a();
}
for (;;)
{
localFragmentHostCallback.j = true;
return;
label37:
if (!localFragmentHostCallback.j)
{
localFragmentHostCallback.i = localFragmentHostCallback.a("(root)", localFragmentHostCallback.k, false);
if ((localFragmentHostCallback.i != null) && (!localFragmentHostCallback.i.e)) {
localFragmentHostCallback.i.a();
}
}
}
}
public void doLoaderStop(boolean paramBoolean)
{
FragmentHostCallback localFragmentHostCallback = this.a;
localFragmentHostCallback.h = paramBoolean;
if ((localFragmentHostCallback.i != null) && (localFragmentHostCallback.k))
{
localFragmentHostCallback.k = false;
if (paramBoolean) {
localFragmentHostCallback.i.c();
}
}
else
{
return;
}
localFragmentHostCallback.i.b();
}
public void dumpLoaders(String paramString, FileDescriptor paramFileDescriptor, PrintWriter paramPrintWriter, String[] paramArrayOfString)
{
FragmentHostCallback localFragmentHostCallback = this.a;
paramPrintWriter.print(paramString);
paramPrintWriter.print("mLoadersStarted=");
paramPrintWriter.println(localFragmentHostCallback.k);
if (localFragmentHostCallback.i != null)
{
paramPrintWriter.print(paramString);
paramPrintWriter.print("Loader Manager ");
paramPrintWriter.print(Integer.toHexString(System.identityHashCode(localFragmentHostCallback.i)));
paramPrintWriter.println(":");
localFragmentHostCallback.i.dump(paramString + " ", paramFileDescriptor, paramPrintWriter, paramArrayOfString);
}
}
public boolean execPendingActions()
{
return this.a.f.b();
}
@Nullable
public Fragment findFragmentByWho(String paramString)
{
return this.a.f.a(paramString);
}
public List<Fragment> getActiveFragments(List<Fragment> paramList)
{
if (this.a.f.e == null) {
return null;
}
Object localObject = paramList;
if (paramList == null) {
localObject = new ArrayList(getActiveFragmentsCount());
}
((List)localObject).addAll(this.a.f.e);
return (List<Fragment>)localObject;
}
public int getActiveFragmentsCount()
{
ArrayList localArrayList = this.a.f.e;
if (localArrayList == null) {
return 0;
}
return localArrayList.size();
}
public FragmentManager getSupportFragmentManager()
{
return this.a.f;
}
public LoaderManager getSupportLoaderManager()
{
FragmentHostCallback localFragmentHostCallback = this.a;
if (localFragmentHostCallback.i != null) {
return localFragmentHostCallback.i;
}
localFragmentHostCallback.j = true;
localFragmentHostCallback.i = localFragmentHostCallback.a("(root)", localFragmentHostCallback.k, true);
return localFragmentHostCallback.i;
}
public void noteStateNotSaved()
{
this.a.f.s = false;
}
public View onCreateView(View paramView, String paramString, Context paramContext, AttributeSet paramAttributeSet)
{
return this.a.f.onCreateView(paramView, paramString, paramContext, paramAttributeSet);
}
public void reportLoaderStart()
{
FragmentHostCallback localFragmentHostCallback = this.a;
if (localFragmentHostCallback.g != null)
{
int k = localFragmentHostCallback.g.size();
cq[] arrayOfcq = new cq[k];
int i = k - 1;
while (i >= 0)
{
arrayOfcq[i] = ((cq)localFragmentHostCallback.g.valueAt(i));
i -= 1;
}
i = 0;
while (i < k)
{
localFragmentHostCallback = arrayOfcq[i];
if (localFragmentHostCallback.f)
{
if (cq.a) {
Log.v("LoaderManager", "Finished Retaining in " + localFragmentHostCallback);
}
localFragmentHostCallback.f = false;
int j = localFragmentHostCallback.b.size() - 1;
while (j >= 0)
{
cq.a locala = (cq.a)localFragmentHostCallback.b.valueAt(j);
if (locala.i)
{
if (cq.a) {
Log.v("LoaderManager", " Finished Retaining: " + locala);
}
locala.i = false;
if ((locala.h != locala.j) && (!locala.h)) {
locala.b();
}
}
if ((locala.h) && (locala.e) && (!locala.k)) {
locala.a(locala.d, locala.g);
}
j -= 1;
}
}
localFragmentHostCallback.e();
i += 1;
}
}
}
public void restoreAllState(Parcelable paramParcelable, FragmentManagerNonConfig paramFragmentManagerNonConfig)
{
this.a.f.a(paramParcelable, paramFragmentManagerNonConfig);
}
@Deprecated
public void restoreAllState(Parcelable paramParcelable, List<Fragment> paramList)
{
this.a.f.a(paramParcelable, new FragmentManagerNonConfig(paramList, null));
}
public void restoreLoaderNonConfig(SimpleArrayMap<String, LoaderManager> paramSimpleArrayMap)
{
this.a.g = paramSimpleArrayMap;
}
public SimpleArrayMap<String, LoaderManager> retainLoaderNonConfig()
{
int j = 0;
FragmentHostCallback localFragmentHostCallback = this.a;
int k;
if (localFragmentHostCallback.g != null)
{
int m = localFragmentHostCallback.g.size();
cq[] arrayOfcq = new cq[m];
int i = m - 1;
while (i >= 0)
{
arrayOfcq[i] = ((cq)localFragmentHostCallback.g.valueAt(i));
i -= 1;
}
boolean bool = localFragmentHostCallback.h;
i = 0;
k = i;
if (j < m)
{
cq localcq = arrayOfcq[j];
if ((!localcq.f) && (bool))
{
if (!localcq.e) {
localcq.a();
}
localcq.c();
}
if (localcq.f) {
i = 1;
}
for (;;)
{
j += 1;
break;
localcq.f();
localFragmentHostCallback.g.remove(localcq.d);
}
}
}
else
{
k = 0;
}
if (k != 0) {
return localFragmentHostCallback.g;
}
return null;
}
public FragmentManagerNonConfig retainNestedNonConfig()
{
return this.a.f.d();
}
@Deprecated
public List<Fragment> retainNonConfig()
{
FragmentManagerNonConfig localFragmentManagerNonConfig = this.a.f.d();
if (localFragmentManagerNonConfig != null) {
return localFragmentManagerNonConfig.a;
}
return null;
}
public Parcelable saveAllState()
{
return this.a.f.e();
}
}
/* Location: /home/merong/decompile/hackery-dex2jar.jar!/android/support/v4/app/FragmentController.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/