List of usage examples for android.os Bundle getCharSequence
@Override
@Nullable
public CharSequence getCharSequence(@Nullable String key)
From source file:com.ubergeek42.WeechatAndroid.relay.Hotlist.java
private static @Nullable CharSequence getMessageText(Intent intent) { Bundle remoteInput = RemoteInput.getResultsFromIntent(intent); if (remoteInput != null) return remoteInput.getCharSequence(KEY_TEXT_REPLY); return null;/*from w ww. j a v a 2 s. c o m*/ }
From source file:com.android.utils.WebInterfaceUtils.java
public static String[] getSupportedHtmlElements(AccessibilityNodeInfoCompat node) { HashSet<AccessibilityNodeInfoCompat> visitedNodes = new HashSet<AccessibilityNodeInfoCompat>(); while (node != null) { if (visitedNodes.contains(node)) { return null; }/*from ww w .j a va2s . c o m*/ visitedNodes.add(node); Bundle bundle = node.getExtras(); CharSequence supportedHtmlElements = bundle.getCharSequence(ACTION_ARGUMENT_HTML_ELEMENT_STRING_VALUES); if (supportedHtmlElements != null) { return supportedHtmlElements.toString().split(","); } node = node.getParent(); } return null; }
From source file:com.github.pockethub.ui.comment.RenderedCommentFragment.java
@Override public Loader<CharSequence> onCreateLoader(int loader, Bundle args) { final CharSequence raw = args.getCharSequence(ARG_TEXT); final Repo repo = args.getParcelable(ARG_REPO); return new MarkdownLoader(getActivity(), repo, raw.toString(), imageGetter, true); }
From source file:com.github.mobile.ui.comment.RenderedCommentFragment.java
@Override public Loader<CharSequence> onCreateLoader(int loader, Bundle args) { final CharSequence raw = args.getCharSequence(ARG_TEXT); final IRepositoryIdProvider repo = (IRepositoryIdProvider) args.getSerializable(ARG_REPO); return new MarkdownLoader(getActivity(), repo, raw.toString(), imageGetter, true); }
From source file:com.github.pockethub.android.ui.comment.RenderedCommentFragment.java
@Override public Loader<CharSequence> onCreateLoader(int loader, Bundle args) { final CharSequence raw = args.getCharSequence(ARG_TEXT); final Repository repo = args.getParcelable(ARG_REPO); return new MarkdownLoader(getActivity(), repo, raw.toString(), imageGetter, true); }
From source file:edu.csh.coursebrowser.SectionsActivity.java
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_sections); // Show the Up button in the action bar. getActionBar().setDisplayHomeAsUpEnabled(true); Bundle args = this.getIntent().getExtras(); this.setTitle(args.getCharSequence("title")); this.getActionBar().setHomeButtonEnabled(false); TextView tv = (TextView) this.findViewById(R.id.Course_description); tv.setText(args.getString("description")); final String info = this.getIntent().getExtras().getString("args"); Button b = (Button) this.findViewById(R.id.browse_sections); b.setOnClickListener(new OnClickListener() { @Override/* w w w.j a v a2 s. c o m*/ public void onClick(View arg0) { Intent intent = new Intent(SectionsActivity.this, SectionInfoActivity.class); intent.putExtra("title", SectionsActivity.this.getTitle()); intent.putExtra("args", info); startActivity(intent); } }); }
From source file:com.commonsware.android.wearvoice.VoiceReceiver.java
@Override public void onReceive(Context ctxt, Intent i) { Bundle input = RemoteInput.getResultsFromIntent(i); if (input != null) { CharSequence speech = input.getCharSequence(EXTRA_SPEECH); if (speech != null) { Log.d(getClass().getSimpleName(), speech.toString()); } else {//from w ww . j a v a2 s . c o m Log.e(getClass().getSimpleName(), "No voice response speech"); } } else { Log.e(getClass().getSimpleName(), "No voice response Bundle"); } }
From source file:br.com.virtz.www.cfcmob.MessageReplyReceiver.java
/** * Get the message text from the intent. * Note that you should call {@code RemoteInput#getResultsFromIntent(intent)} to process * the RemoteInput./* ww w . java 2 s .c o m*/ */ private CharSequence getMessageText(Intent intent) { Bundle remoteInput = RemoteInput.getResultsFromIntent(intent); if (remoteInput != null) { return remoteInput.getCharSequence(MyMessagingService.EXTRA_VOICE_REPLY); } return null; }
From source file:mycroft.ai.mycroftcore_android.MessageReplyReceiver.java
/** * Get the message text from the intent. * Note that you should call {@code RemoteInput#getResultsFromIntent(intent)} to process * the RemoteInput./*from www . ja v a2s. c om*/ */ private CharSequence getMessageText(Intent intent) { Bundle remoteInput = RemoteInput.getResultsFromIntent(intent); if (remoteInput != null) { return remoteInput.getCharSequence(MycroftMessagingService.EXTRA_VOICE_REPLY); } return null; }
From source file:sg.edu.nus.tasklaundrette.MessageReplyReceiver.java
/** * Get the message text from the intent. * Note that you should call {@code RemoteInput#getResultsFromIntent(intent)} to process * the RemoteInput.//from w ww . ja v a 2 s. c o m */ private CharSequence getMessageText(Intent intent) { Bundle remoteInput = RemoteInput.getResultsFromIntent(intent); if (remoteInput != null) { return remoteInput.getCharSequence(ChatMessagingService.EXTRA_VOICE_REPLY); } return null; }