Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Remove debug

vishnukvmd24f2ac2d8b13
diff --git a/mobile/lib/ui/home/landing_page_widget.dart b/mobile/lib/ui/home/landing_page_widget.dart
index fdaa7c0777..bdc1e8a03e 100644
--- a/mobile/lib/ui/home/landing_page_widget.dart
+++ b/mobile/lib/ui/home/landing_page_widget.dart
@@ -4,9 +4,6 @@ import 'dart:io';
import 'package:dots_indicator/dots_indicator.dart';
import "package:flutter/foundation.dart";
import 'package:flutter/material.dart';
-import "package:flutter_app_icon_changer/flutter_app_icon_changer.dart";
-import "package:launcher_icon_switcher/launcher_icon_switcher.dart";
-import "package:logging/logging.dart";
import "package:photos/app.dart";
import 'package:photos/core/configuration.dart';
import 'package:photos/ente_theme_data.dart';
@@ -21,7 +18,6 @@ import 'package:photos/ui/common/gradient_button.dart';
import 'package:photos/ui/components/buttons/button_widget.dart';
import 'package:photos/ui/components/dialog_widget.dart';
import 'package:photos/ui/components/models/button_type.dart';
-import "package:photos/ui/home/custom_icons.dart";
import 'package:photos/ui/payment/subscription.dart';
import "package:photos/ui/settings/developer_settings_page.dart";
import "package:photos/ui/settings/developer_settings_widget.dart";
@@ -159,7 +155,7 @@ class _LandingPageWidgetState extends State<LandingPageWidget> {
key: const ValueKey("signInButton"),
style:
Theme.of(context).colorScheme.optionalActionButtonStyle,
- onPressed: _changeIcon,
+ onPressed: _navigateToSignInPage,
child: Text(
S.of(context).existingUser,
style: const TextStyle(
@@ -257,55 +253,6 @@ class _LandingPageWidgetState extends State<LandingPageWidget> {
);
}
- Future<void> _changeIcon() async {
- Logger("Icon").info("Initializing");
- final iconChanger = LauncherIconSwitcher();
- await iconChanger
- .initialize(['IconLight', 'IconDark', 'IconGreen'], 'IconLight');
- Logger("Icon").info("Initialized");
- final currentIcon = await iconChanger.getCurrentIcon();
- Logger("Icon").info("Current Icon: " + currentIcon);
- if (currentIcon == 'IconLight') {
- await iconChanger.setIcon('IconDark');
- } else if (currentIcon == 'IconDark') {
- await iconChanger.setIcon('IconGreen');
- } else {
- await iconChanger.setIcon('IconLight');
- }
- Logger("Icon").info("Changed");
- }
-
- Future<void> _changeIcon2() async {
- try {
- Logger("Icon").info("Initializing");
- final iconChanger = FlutterAppIconChangerPlugin(
- iconsSet: CustomIcons.list,
- );
- final defaultIcon = CustomIcons.list.firstWhere(
- (element) => element.isDefaultIcon,
- );
- Logger("Icon").info("Initialized");
- final currentIcon =
- await iconChanger.getCurrentIcon() ?? defaultIcon.androidIcon;
- Logger("Icon").info("Current Icon: " + currentIcon);
- final isSupported = await iconChanger.isSupported();
- Logger("Icon").info("Supported: " + isSupported.toString());
- if (currentIcon == CustomIcons.list[0].androidIcon) {
- await iconChanger.changeIcon(CustomIcons.list[1].androidIcon);
- } else if (currentIcon == CustomIcons.list[1].androidIcon) {
- await iconChanger.changeIcon(CustomIcons.list[2].androidIcon);
- } else {
- await iconChanger.changeIcon(CustomIcons.list[0].androidIcon);
- }
- final newIcon =
- await iconChanger.getCurrentIcon() ?? defaultIcon.androidIcon;
- Logger("Icon").info("App icon changed to " + newIcon);
- return;
- } catch (e, s) {
- Logger("Icon").severe(e, s);
- }
- }
-
void _navigateToSignInPage() {
updateService.hideChangeLog().ignore();
Widget page;