如何获取之前设置的textswitcher中的文本.就像textview.getText()一样.我尝试了以下代码,但没有奏效.
TextSwitcher textSwitcher = (TextSwitcher)findViewById(...);
TextView currentlyShownTextView = (TextView) textSwitcher.getCurrentView();
String currentlyShownText = textSwitcher.getText().toString();
Run Code Online (Sandbox Code Playgroud)