SearchViewCompat.java
9.67 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
package android.support.v4.widget;
import android.app.SearchManager;
import android.content.ComponentName;
import android.content.Context;
import android.os.Build.VERSION;
import android.view.View;
import android.widget.SearchView;
import android.widget.SearchView.OnCloseListener;
import android.widget.SearchView.OnQueryTextListener;
import fa.1;
import fa.2;
import fa.a;
import fa.b;
public final class SearchViewCompat
{
private static final c a = new d();
static
{
if (Build.VERSION.SDK_INT >= 14)
{
a = new b();
return;
}
if (Build.VERSION.SDK_INT >= 11)
{
a = new a();
return;
}
}
public static CharSequence getQuery(View paramView)
{
return a.a(paramView);
}
public static boolean isIconified(View paramView)
{
return a.b(paramView);
}
public static boolean isQueryRefinementEnabled(View paramView)
{
return a.d(paramView);
}
public static boolean isSubmitButtonEnabled(View paramView)
{
return a.c(paramView);
}
public static View newSearchView(Context paramContext)
{
return a.a(paramContext);
}
public static void setIconified(View paramView, boolean paramBoolean)
{
a.a(paramView, paramBoolean);
}
public static void setImeOptions(View paramView, int paramInt)
{
a.b(paramView, paramInt);
}
public static void setInputType(View paramView, int paramInt)
{
a.c(paramView, paramInt);
}
public static void setMaxWidth(View paramView, int paramInt)
{
a.a(paramView, paramInt);
}
public static void setOnCloseListener(View paramView, OnCloseListener paramOnCloseListener)
{
a.a(paramView, paramOnCloseListener);
}
public static void setOnQueryTextListener(View paramView, OnQueryTextListener paramOnQueryTextListener)
{
a.a(paramView, paramOnQueryTextListener);
}
public static void setQuery(View paramView, CharSequence paramCharSequence, boolean paramBoolean)
{
a.a(paramView, paramCharSequence, paramBoolean);
}
public static void setQueryHint(View paramView, CharSequence paramCharSequence)
{
a.a(paramView, paramCharSequence);
}
public static void setQueryRefinementEnabled(View paramView, boolean paramBoolean)
{
a.c(paramView, paramBoolean);
}
public static void setSearchableInfo(View paramView, ComponentName paramComponentName)
{
a.a(paramView, paramComponentName);
}
public static void setSubmitButtonEnabled(View paramView, boolean paramBoolean)
{
a.b(paramView, paramBoolean);
}
public static abstract interface OnCloseListener
{
public abstract boolean onClose();
}
@Deprecated
public static abstract class OnCloseListenerCompat
implements SearchViewCompat.OnCloseListener
{
public boolean onClose()
{
return false;
}
}
public static abstract interface OnQueryTextListener
{
public abstract boolean onQueryTextChange(String paramString);
public abstract boolean onQueryTextSubmit(String paramString);
}
@Deprecated
public static abstract class OnQueryTextListenerCompat
implements SearchViewCompat.OnQueryTextListener
{
public boolean onQueryTextChange(String paramString)
{
return false;
}
public boolean onQueryTextSubmit(String paramString)
{
return false;
}
}
static class a
extends SearchViewCompat.d
{
protected static void e(View paramView)
{
if (paramView == null) {
throw new IllegalArgumentException("searchView must be non-null");
}
if (!(paramView instanceof SearchView)) {
throw new IllegalArgumentException("searchView must be an instance ofandroid.widget.SearchView");
}
}
public View a(Context paramContext)
{
return new SearchView(paramContext);
}
public final CharSequence a(View paramView)
{
e(paramView);
return ((SearchView)paramView).getQuery();
}
public final void a(View paramView, int paramInt)
{
e(paramView);
((SearchView)paramView).setMaxWidth(paramInt);
}
public final void a(View paramView, ComponentName paramComponentName)
{
e(paramView);
paramView = (SearchView)paramView;
paramView.setSearchableInfo(((SearchManager)paramView.getContext().getSystemService("search")).getSearchableInfo(paramComponentName));
}
public final void a(View paramView, final SearchViewCompat.OnCloseListener paramOnCloseListener)
{
e(paramView);
paramOnCloseListener = new fa.2(new fa.a()
{
public final boolean a()
{
return paramOnCloseListener.onClose();
}
});
((SearchView)paramView).setOnCloseListener((SearchView.OnCloseListener)paramOnCloseListener);
}
public final void a(View paramView, final SearchViewCompat.OnQueryTextListener paramOnQueryTextListener)
{
e(paramView);
paramOnQueryTextListener = new fa.1(new fa.b()
{
public final boolean a(String paramAnonymousString)
{
return paramOnQueryTextListener.onQueryTextSubmit(paramAnonymousString);
}
public final boolean b(String paramAnonymousString)
{
return paramOnQueryTextListener.onQueryTextChange(paramAnonymousString);
}
});
((SearchView)paramView).setOnQueryTextListener((SearchView.OnQueryTextListener)paramOnQueryTextListener);
}
public final void a(View paramView, CharSequence paramCharSequence)
{
e(paramView);
((SearchView)paramView).setQueryHint(paramCharSequence);
}
public final void a(View paramView, CharSequence paramCharSequence, boolean paramBoolean)
{
e(paramView);
((SearchView)paramView).setQuery(paramCharSequence, paramBoolean);
}
public final void a(View paramView, boolean paramBoolean)
{
e(paramView);
((SearchView)paramView).setIconified(paramBoolean);
}
public final void b(View paramView, boolean paramBoolean)
{
e(paramView);
((SearchView)paramView).setSubmitButtonEnabled(paramBoolean);
}
public final boolean b(View paramView)
{
e(paramView);
return ((SearchView)paramView).isIconified();
}
public final void c(View paramView, boolean paramBoolean)
{
e(paramView);
((SearchView)paramView).setQueryRefinementEnabled(paramBoolean);
}
public final boolean c(View paramView)
{
e(paramView);
return ((SearchView)paramView).isSubmitButtonEnabled();
}
public final boolean d(View paramView)
{
e(paramView);
return ((SearchView)paramView).isQueryRefinementEnabled();
}
}
static final class b
extends SearchViewCompat.a
{
public final View a(Context paramContext)
{
return new SearchViewCompatIcs.MySearchView(paramContext);
}
public final void b(View paramView, int paramInt)
{
e(paramView);
((SearchView)paramView).setImeOptions(paramInt);
}
public final void c(View paramView, int paramInt)
{
e(paramView);
((SearchView)paramView).setInputType(paramInt);
}
}
static abstract interface c
{
public abstract View a(Context paramContext);
public abstract CharSequence a(View paramView);
public abstract void a(View paramView, int paramInt);
public abstract void a(View paramView, ComponentName paramComponentName);
public abstract void a(View paramView, SearchViewCompat.OnCloseListener paramOnCloseListener);
public abstract void a(View paramView, SearchViewCompat.OnQueryTextListener paramOnQueryTextListener);
public abstract void a(View paramView, CharSequence paramCharSequence);
public abstract void a(View paramView, CharSequence paramCharSequence, boolean paramBoolean);
public abstract void a(View paramView, boolean paramBoolean);
public abstract void b(View paramView, int paramInt);
public abstract void b(View paramView, boolean paramBoolean);
public abstract boolean b(View paramView);
public abstract void c(View paramView, int paramInt);
public abstract void c(View paramView, boolean paramBoolean);
public abstract boolean c(View paramView);
public abstract boolean d(View paramView);
}
static class d
implements SearchViewCompat.c
{
public View a(Context paramContext)
{
return null;
}
public CharSequence a(View paramView)
{
return null;
}
public void a(View paramView, int paramInt) {}
public void a(View paramView, ComponentName paramComponentName) {}
public void a(View paramView, SearchViewCompat.OnCloseListener paramOnCloseListener) {}
public void a(View paramView, SearchViewCompat.OnQueryTextListener paramOnQueryTextListener) {}
public void a(View paramView, CharSequence paramCharSequence) {}
public void a(View paramView, CharSequence paramCharSequence, boolean paramBoolean) {}
public void a(View paramView, boolean paramBoolean) {}
public void b(View paramView, int paramInt) {}
public void b(View paramView, boolean paramBoolean) {}
public boolean b(View paramView)
{
return true;
}
public void c(View paramView, int paramInt) {}
public void c(View paramView, boolean paramBoolean) {}
public boolean c(View paramView)
{
return false;
}
public boolean d(View paramView)
{
return false;
}
}
}
/* Location: /home/merong/decompile/hackery-dex2jar.jar!/android/support/v4/widget/SearchViewCompat.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/