switchScreen method

void switchScreen(
  1. String screen, {
  2. List<String>? options,
  3. String? user,
  4. String? device,
  5. List<String>? tokens,
})

Implementation

void switchScreen(String screen, {List<String>? options, String? user, String? device, List<String>? tokens}) {
  setState(() {
    currentScreen = screen;
    if (options != null) {
      entityOptions = options;
    }
    if (user != null) {
      username = user;
    }
    if (device != null) {
      deviceId = device;
    }
    if (tokens != null) {
      refreshTokens = tokens;
    }
  });
}