Interface Focusable
- All Known Implementing Classes:
SimpleListModel
public interface Focusable
Ability to focus view. Mostly used to focus detail view in list-detail view pattern. First set setOnFocusView which will be used when calling
focusView.
class FocusableImpl implements Focusable {
private Runnable onFocusView;
public void focusView() {
if (onFocusView != null) {
onFocusView.run();
}
}
public void setOnFocusView(Runnable command) {
onFocusView = command;
}
}
-
Method Summary
Modifier and TypeMethodDescriptionvoidRuns predefined command set bysetOnFocusView(java.lang.Runnable).voidsetOnFocusView(Runnable command) Sets the command which should be executed infocusView().
-
Method Details
-
focusView
void focusView()Runs predefined command set bysetOnFocusView(java.lang.Runnable). -
setOnFocusView
Sets the command which should be executed infocusView().
-