diff --git a/daemon.py b/daemon.py index abee985c8..485bc1da8 100644 --- a/daemon.py +++ b/daemon.py @@ -384,7 +384,6 @@ class EpicyonServer(ThreadingHTTPServer): max_followers = 2000 show_publish_as_icon = False full_width_tl_button_header = False - icons_as_buttons = False rss_icon_at_top = True publish_button_at_top = False max_feed_item_size_kb = 100 @@ -619,7 +618,6 @@ def run_daemon(accounts_data_dir: str, max_feed_item_size_kb: int, publish_button_at_top: bool, rss_icon_at_top: bool, - icons_as_buttons: bool, full_width_tl_button_header: bool, show_publish_as_icon: bool, max_followers: int, @@ -1076,9 +1074,6 @@ def run_daemon(accounts_data_dir: str, # calendar, etc as the full width of the screen or not httpd.full_width_tl_button_header = full_width_tl_button_header - # whether to show icons in the header (eg calendar) as buttons - httpd.icons_as_buttons = False - # whether to show the RSS icon at the top or the bottom of the timeline httpd.rss_icon_at_top = rss_icon_at_top diff --git a/daemon_get.py b/daemon_get.py index 33c4efe42..2fae6a0f7 100644 --- a/daemon_get.py +++ b/daemon_get.py @@ -2981,7 +2981,6 @@ def daemon_http_get(self) -> None: '/users/' + nickname + '/' + self.server.default_timeline show_publish_as_icon = self.server.show_publish_as_icon rss_icon_at_top = self.server.rss_icon_at_top - icons_as_buttons = False default_timeline = self.server.default_timeline access_keys = self.server.access_keys if self.server.key_shortcuts.get(nickname): @@ -2998,7 +2997,6 @@ def daemon_http_get(self) -> None: show_publish_as_icon, authorized, rss_icon_at_top, - icons_as_buttons, default_timeline, self.server.theme_name, access_keys, @@ -3026,7 +3024,6 @@ def daemon_http_get(self) -> None: access_keys = self.server.key_shortcuts[nickname] timeline_path = \ '/users/' + nickname + '/' + self.server.default_timeline - icons_as_buttons = False default_timeline = self.server.default_timeline shared_items_domains = \ self.server.shared_items_federated_domains @@ -3039,7 +3036,6 @@ def daemon_http_get(self) -> None: timeline_path, authorized, self.server.rss_icon_at_top, - icons_as_buttons, default_timeline, self.server.theme_name, access_keys, @@ -4720,7 +4716,6 @@ def daemon_http_get(self) -> None: self.server.cached_webfingers, self.server.yt_replace_domain, self.server.twitter_replacement_domain, - self.server.icons_as_buttons, self.server.access_keys, self.server.key_shortcuts, self.server.city, @@ -4779,7 +4774,6 @@ def daemon_http_get(self) -> None: self.server.yt_replace_domain, self.server.twitter_replacement_domain, self.server.show_published_date_only, - self.server.icons_as_buttons, self.server.allow_local_network_access, self.server.access_keys, self.server.key_shortcuts, @@ -4951,7 +4945,6 @@ def daemon_http_get(self) -> None: self.server.show_published_date_only, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5012,7 +5005,6 @@ def daemon_http_get(self) -> None: self.server.yt_replace_domain, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5073,7 +5065,6 @@ def daemon_http_get(self) -> None: self.server.yt_replace_domain, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5134,7 +5125,6 @@ def daemon_http_get(self) -> None: self.server.show_published_date_only, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5198,7 +5188,6 @@ def daemon_http_get(self) -> None: self.server.show_published_date_only, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5260,7 +5249,6 @@ def daemon_http_get(self) -> None: self.server.show_published_date_only, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5322,7 +5310,6 @@ def daemon_http_get(self) -> None: self.server.yt_replace_domain, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5379,7 +5366,6 @@ def daemon_http_get(self) -> None: self.server.newswire, self.server.positive_voting, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5433,7 +5419,6 @@ def daemon_http_get(self) -> None: self.server.newswire, self.server.positive_voting, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5586,7 +5571,6 @@ def daemon_http_get(self) -> None: self.server.yt_replace_domain, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5648,7 +5632,6 @@ def daemon_http_get(self) -> None: self.server.show_published_date_only, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5715,7 +5698,6 @@ def daemon_http_get(self) -> None: self.server.yt_replace_domain, self.server.newswire, self.server.show_publish_as_icon, - self.server.icons_as_buttons, self.server.rss_icon_at_top, self.server.publish_button_at_top, self.server.theme_name, @@ -5759,7 +5741,6 @@ def daemon_http_get(self) -> None: self.server.bold_reading, self.server.signing_priv_key_pem, self.server.rss_icon_at_top, - self.server.icons_as_buttons, self.server.default_timeline, self.server.recent_posts_cache, self.server.max_recent_posts, @@ -5821,7 +5802,6 @@ def daemon_http_get(self) -> None: self.server.sites_unavailable, self.server.signing_priv_key_pem, self.server.rss_icon_at_top, - self.server.icons_as_buttons, self.server.default_timeline, self.server.recent_posts_cache, self.server.max_recent_posts, @@ -5879,7 +5859,6 @@ def daemon_http_get(self) -> None: self.server.sites_unavailable, self.server.signing_priv_key_pem, self.server.rss_icon_at_top, - self.server.icons_as_buttons, self.server.default_timeline, self.server.recent_posts_cache, self.server.max_recent_posts, @@ -5939,7 +5918,6 @@ def daemon_http_get(self) -> None: self.server.max_shares_on_profile, self.server.signing_priv_key_pem, self.server.rss_icon_at_top, - self.server.icons_as_buttons, self.server.default_timeline, self.server.recent_posts_cache, self.server.max_recent_posts, @@ -5997,7 +5975,6 @@ def daemon_http_get(self) -> None: self.server.sites_unavailable, self.server.signing_priv_key_pem, self.server.rss_icon_at_top, - self.server.icons_as_buttons, self.server.default_timeline, self.server.recent_posts_cache, self.server.max_recent_posts, @@ -6056,7 +6033,6 @@ def daemon_http_get(self) -> None: self.server.fitness, self.server.signing_priv_key_pem, self.server.rss_icon_at_top, - self.server.icons_as_buttons, self.server.default_timeline, self.server.recent_posts_cache, self.server.max_recent_posts, diff --git a/daemon_get_feeds.py b/daemon_get_feeds.py index 98a1ce20c..3e387e568 100644 --- a/daemon_get_feeds.py +++ b/daemon_get_feeds.py @@ -40,7 +40,6 @@ def show_shares_feed(self, authorized: bool, bold_reading_nicknames: {}, signing_priv_key_pem: str, rss_icon_at_top: bool, - icons_as_buttons: bool, default_timeline: str, recent_posts_cache: {}, max_recent_posts: int, @@ -135,7 +134,6 @@ def show_shares_feed(self, authorized: bool, msg = \ html_profile(signing_priv_key_pem, rss_icon_at_top, - icons_as_buttons, default_timeline, recent_posts_cache, max_recent_posts, @@ -232,7 +230,6 @@ def show_following_feed(self, authorized: bool, sites_unavailable: [], signing_priv_key_pem: str, rss_icon_at_top: bool, - icons_as_buttons: bool, default_timeline: str, recent_posts_cache: {}, max_recent_posts: int, @@ -330,7 +327,6 @@ def show_following_feed(self, authorized: bool, msg = \ html_profile(signing_priv_key_pem, rss_icon_at_top, - icons_as_buttons, default_timeline, recent_posts_cache, max_recent_posts, @@ -434,7 +430,6 @@ def show_moved_feed(self, authorized: bool, sites_unavailable: [], signing_priv_key_pem: str, rss_icon_at_top: bool, - icons_as_buttons: bool, default_timeline: str, recent_posts_cache: {}, max_recent_posts: int, @@ -527,7 +522,6 @@ def show_moved_feed(self, authorized: bool, msg = \ html_profile(signing_priv_key_pem, rss_icon_at_top, - icons_as_buttons, default_timeline, recent_posts_cache, max_recent_posts, @@ -624,7 +618,6 @@ def show_inactive_feed(self, authorized: bool, max_shares_on_profile: int, signing_priv_key_pem: str, rss_icon_at_top: bool, - icons_as_buttons: bool, default_timeline: str, recent_posts_cache: {}, max_recent_posts: int, @@ -717,7 +710,6 @@ def show_inactive_feed(self, authorized: bool, msg = \ html_profile(signing_priv_key_pem, rss_icon_at_top, - icons_as_buttons, default_timeline, recent_posts_cache, max_recent_posts, @@ -815,7 +807,6 @@ def show_followers_feed(self, authorized: bool, sites_unavailable: [], signing_priv_key_pem: str, rss_icon_at_top: bool, - icons_as_buttons: bool, default_timeline: str, recent_posts_cache: {}, max_recent_posts: int, @@ -909,7 +900,6 @@ def show_followers_feed(self, authorized: bool, msg = \ html_profile(signing_priv_key_pem, rss_icon_at_top, - icons_as_buttons, default_timeline, recent_posts_cache, max_recent_posts, diff --git a/daemon_get_profile.py b/daemon_get_profile.py index 18ab59a94..9fd7eb9ce 100644 --- a/daemon_get_profile.py +++ b/daemon_get_profile.py @@ -55,7 +55,6 @@ def show_person_profile(self, authorized: bool, fitness: {}, signing_priv_key_pem: str, rss_icon_at_top: bool, - icons_as_buttons: bool, default_timeline: str, recent_posts_cache: {}, max_recent_posts: int, @@ -121,7 +120,6 @@ def show_person_profile(self, authorized: bool, msg = \ html_profile(signing_priv_key_pem, rss_icon_at_top, - icons_as_buttons, default_timeline, recent_posts_cache, max_recent_posts, @@ -216,7 +214,6 @@ def show_roles(self, calling_domain: str, referer_domain: str, cached_webfingers: {}, yt_replace_domain: str, twitter_replacement_domain: str, - icons_as_buttons: bool, access_keys: {}, key_shortcuts: {}, city: str, signing_priv_key_pem: str, @@ -291,7 +288,6 @@ def show_roles(self, calling_domain: str, referer_domain: str, msg = \ html_profile(signing_priv_key_pem, rss_icon_at_top, - icons_as_buttons, default_timeline, recent_posts_cache, max_recent_posts, @@ -373,7 +369,6 @@ def show_skills(self, calling_domain: str, referer_domain: str, yt_replace_domain: str, twitter_replacement_domain: str, show_published_date_only: bool, - icons_as_buttons: bool, allow_local_network_access: bool, access_keys: {}, key_shortcuts: {}, @@ -448,7 +443,6 @@ def show_skills(self, calling_domain: str, referer_domain: str, msg = \ html_profile(signing_priv_key_pem, rss_icon_at_top, - icons_as_buttons, default_timeline, recent_posts_cache, max_recent_posts, diff --git a/daemon_get_timeline.py b/daemon_get_timeline.py index 3ae5dcd22..ed8531c32 100644 --- a/daemon_get_timeline.py +++ b/daemon_get_timeline.py @@ -66,7 +66,6 @@ def show_media_timeline(self, authorized: bool, show_published_date_only: bool, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -183,7 +182,6 @@ def show_media_timeline(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, @@ -286,7 +284,6 @@ def show_blogs_timeline(self, authorized: bool, show_published_date_only: bool, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -398,7 +395,6 @@ def show_blogs_timeline(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, @@ -499,7 +495,6 @@ def show_news_timeline(self, authorized: bool, show_published_date_only: bool, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -617,7 +612,6 @@ def show_news_timeline(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, @@ -718,7 +712,6 @@ def show_features_timeline(self, authorized: bool, yt_replace_domain: str, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -830,7 +823,6 @@ def show_features_timeline(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, @@ -927,7 +919,6 @@ def show_shares_timeline(self, authorized: bool, newswire: {}, positive_voting: bool, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -1004,7 +995,6 @@ def show_shares_timeline(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, theme_name, @@ -1077,7 +1067,6 @@ def show_wanted_timeline(self, authorized: bool, newswire: {}, positive_voting: bool, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -1153,7 +1142,6 @@ def show_wanted_timeline(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, theme_name, @@ -1230,7 +1218,6 @@ def show_bookmarks_timeline(self, authorized: bool, yt_replace_domain: str, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -1337,7 +1324,6 @@ def show_bookmarks_timeline(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, @@ -1438,7 +1424,6 @@ def show_outbox_timeline(self, authorized: bool, show_published_date_only: bool, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -1557,7 +1542,6 @@ def show_outbox_timeline(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, @@ -1648,7 +1632,6 @@ def show_mod_timeline(self, authorized: bool, yt_replace_domain: str, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -1752,7 +1735,6 @@ def show_mod_timeline(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, moderation_action_str, @@ -1852,7 +1834,6 @@ def show_dms(self, authorized: bool, yt_replace_domain: str, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -1963,7 +1944,6 @@ def show_dms(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, theme_name, @@ -2064,7 +2044,6 @@ def show_replies(self, authorized: bool, yt_replace_domain: str, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -2175,7 +2154,6 @@ def show_replies(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, theme_name, @@ -2277,7 +2255,6 @@ def show_inbox(self, authorized: bool, show_published_date_only: bool, newswire: {}, show_publish_as_icon: bool, - icons_as_buttons: bool, rss_icon_at_top: bool, publish_button_at_top: bool, theme_name: str, @@ -2399,7 +2376,6 @@ def show_inbox(self, authorized: bool, positive_voting, show_publish_as_icon, full_width_tl_button_header, - icons_as_buttons, rss_icon_at_top, publish_button_at_top, authorized, diff --git a/daemon_post_profile.py b/daemon_post_profile.py index 2fd46268a..f72467c9a 100644 --- a/daemon_post_profile.py +++ b/daemon_post_profile.py @@ -1444,7 +1444,6 @@ def _profile_post_remove_custom_font(base_dir: str, nickname: str, domain: str, get_config_param(base_dir, 'showPublishAsIcon') self.server.full_width_tl_button_header = \ get_config_param(base_dir, 'fullWidthTimelineButtonHeader') - self.server.icons_as_buttons = False self.server.rss_icon_at_top = \ get_config_param(base_dir, 'rssIconAtTop') self.server.publish_button_at_top = \ @@ -2616,7 +2615,6 @@ def _profile_post_theme_change(base_dir: str, nickname: str, get_config_param(base_dir, 'showPublishAsIcon') self.server.full_width_tl_button_header = \ get_config_param(base_dir, 'fullWidthTlButtonHeader') - self.server.icons_as_buttons = False self.server.rss_icon_at_top = \ get_config_param(base_dir, 'rssIconAtTop') self.server.publish_button_at_top = \ diff --git a/epicyon.py b/epicyon.py index 73d583254..ec7dcc0dd 100644 --- a/epicyon.py +++ b/epicyon.py @@ -525,11 +525,6 @@ def _command_options() -> None: help="Whether to show the timeline " + "button header containing inbox and outbox " + "as the full width of the screen") - parser.add_argument("--icons_as_buttons", - dest='icons_as_buttons', - type=str2bool, nargs='?', - const=True, default=False, - help="Show header icons as buttons") parser.add_argument("--log_login_failures", dest='log_login_failures', type=str2bool, nargs='?', @@ -4159,8 +4154,6 @@ def _command_options() -> None: if show_publish_as_icon is not None: argb.show_publish_as_icon = bool(show_publish_as_icon) - icons_as_buttons = False - rss_icon_at_top = \ get_config_param(base_dir, 'rssIconAtTop') if rss_icon_at_top is not None: @@ -4353,7 +4346,6 @@ if __name__ == "__main__": argb2.max_feed_item_size_kb, argb2.publish_button_at_top, argb2.rss_icon_at_top, - argb2.icons_as_buttons, argb2.full_width_tl_button_header, argb2.show_publish_as_icon, argb2.max_followers, diff --git a/tests.py b/tests.py index aa8842092..f16f442d0 100644 --- a/tests.py +++ b/tests.py @@ -938,7 +938,7 @@ def create_server_alice(path: str, domain: str, port: int, send_threads_timeout_mins, dormant_months, max_newswire_posts, allow_local_network_access, - 2048, False, True, False, False, True, max_followers, + 2048, False, True, False, True, max_followers, 0, 100, 1024, 5, False, 0, False, 1, False, False, False, 5, True, True, 'en', __version__, @@ -1139,7 +1139,7 @@ def create_server_bob(path: str, domain: str, port: int, send_threads_timeout_mins, dormant_months, max_newswire_posts, allow_local_network_access, - 2048, False, True, False, False, True, max_followers, + 2048, False, True, False, True, max_followers, 0, 100, 1024, 5, False, 0, False, 1, False, False, False, 5, True, True, 'en', __version__, @@ -1245,7 +1245,7 @@ def create_server_eve(path: str, domain: str, port: int, federation_list: [], dormant_months, max_newswire_posts, allow_local_network_access, - 2048, False, True, False, False, True, + 2048, False, True, False, True, max_followers, 0, 100, 1024, 5, False, 0, False, 1, False, False, False, @@ -1361,7 +1361,7 @@ def create_server_group(path: str, domain: str, port: int, send_threads_timeout_mins, dormant_months, max_newswire_posts, allow_local_network_access, - 2048, False, True, False, False, True, max_followers, + 2048, False, True, False, True, max_followers, 0, 100, 1024, 5, False, 0, False, 1, False, False, False, 5, True, True, 'en', __version__, diff --git a/theme.py b/theme.py index 8d6530607..45b84e70e 100644 --- a/theme.py +++ b/theme.py @@ -205,20 +205,6 @@ def _set_newswire_publish_as_icon(base_dir: str, use_icon: bool) -> bool: return save_json(config_json, config_filename) -def _set_icons_as_buttons(base_dir: str, use_buttons: bool) -> bool: - """Whether to show icons in the header (inbox, outbox, etc) - as buttons - """ - config_filename = base_dir + '/config.json' - if not os.path.isfile(config_filename): - return False - config_json = load_json(config_filename) - if not config_json: - return False - config_json['iconsAsButtons'] = use_buttons - return save_json(config_json, config_filename) - - def _set_rss_icon_at_top(base_dir: str, at_top: bool) -> bool: """Whether to show RSS icon at the top of the timeline """ @@ -383,12 +369,6 @@ def _set_theme_from_dict(base_dir: str, name: str, else: _set_full_width_timeline_button_header(base_dir, False) continue - if param_name == 'icons-as-buttons': - if param_value.lower() == 'true': - _set_icons_as_buttons(base_dir, True) - else: - _set_icons_as_buttons(base_dir, False) - continue if param_name == 'rss-icon-at-top': if param_value.lower() == 'true': _set_rss_icon_at_top(base_dir, True) diff --git a/webapp_column_left.py b/webapp_column_left.py index 9da4c14bc..ed3a782fd 100644 --- a/webapp_column_left.py +++ b/webapp_column_left.py @@ -378,7 +378,6 @@ def html_links_mobile(base_dir: str, http_prefix: str, translate, timeline_path: str, authorized: bool, rss_icon_at_top: bool, - icons_as_buttons: bool, default_timeline: str, theme: str, access_keys: {}, shared_items_federated_domains: [], @@ -420,8 +419,7 @@ def html_links_mobile(base_dir: str, html_str += '