예제 #1
0
 public void addLast(String elem) {
   this.items.add(elem);
   this.notifyDataSetChanged();
   try {
     FocusedSettings.set(getContext(), this.items);
   } catch (IOException e) {
     FLog.d("message", e);
   }
 }
예제 #2
0
 public void deleteAt(int position) {
   String text = this.items.get(position);
   this.items.remove(position);
   notifyDataSetChanged();
   try {
     FocusedSettings.set(getContext(), this.items);
   } catch (IOException e) {
     FLog.d("message", e);
   }
   Toast.makeText(getContext(), "「" + text + "」をキーワードから削除しました", Toast.LENGTH_LONG).show();
 }
 public static void clickNotification(@NonNull AccessibilityEvent event) {
   Parcelable parcelable = event.getParcelableData();
   if (parcelable instanceof Notification) {
     Notification notification = (Notification) parcelable;
     PendingIntent pendingIntent = notification.contentIntent;
     try {
       pendingIntent.send();
     } catch (PendingIntent.CanceledException e) {
       if (DEBUG) FLog.e(e);
     }
   }
 }