From 5a64ac1c10801dda3323163b9a308da5875a0393 Mon Sep 17 00:00:00 2001 From: tkashkin Date: Sun, 2 Apr 2023 18:42:20 +0300 Subject: [PATCH] Additional patches to show more headerbar buttons --- Adwaita/resource/menus/steam.menu | 2 +- extras/patches/headerbar/all.patch | 86 ++++++++++++++++++++++++ extras/patches/headerbar/downloads.patch | 78 +++++++++++++++++++++ extras/patches/headerbar/friends.patch | 19 ++++++ 4 files changed, 184 insertions(+), 1 deletion(-) create mode 100644 extras/patches/headerbar/all.patch create mode 100644 extras/patches/headerbar/downloads.patch create mode 100644 extras/patches/headerbar/friends.patch diff --git a/Adwaita/resource/menus/steam.menu b/Adwaita/resource/menus/steam.menu index 0c5fb185..9fb8fe09 100644 --- a/Adwaita/resource/menus/steam.menu +++ b/Adwaita/resource/menus/steam.menu @@ -4,7 +4,7 @@ menubar { text="" - SkinVersion { text="Adwaita for Steam v0.35" shellcmd="steam://openurl/https://github.com/tkashkin/Adwaita-for-Steam" } + SkinVersion { text="Adwaita for Steam v0.36" shellcmd="steam://openurl/https://github.com/tkashkin/Adwaita-for-Steam" } Divider {} diff --git a/extras/patches/headerbar/all.patch b/extras/patches/headerbar/all.patch new file mode 100644 index 00000000..a057136c --- /dev/null +++ b/extras/patches/headerbar/all.patch @@ -0,0 +1,86 @@ +# Friends and downloads buttons in the main window headerbar +--- Adwaita/resource/layout/steamrootdialog.layout ++++ Adwaita/resource/layout/steamrootdialog.layout +@@ -6,15 +6,14 @@ + + place { control="frame_title" width=max height=48 } + place { control="UINavigatorPanel" width=max height=max } +- place { control="UIStatusPanel" width=max height=2 y=48 } + +- place { control="InboxButton,SupportAlert,ParentalLockButton,MenuBar" width=34 height=34 y=7 margin-right=12 spacing=6 align=right end-right="frame_minimize" } ++ place { control="InboxButton,view_friends,SupportAlert,ParentalLockButton,UIStatusPanel,MenuBar" width=34 height=34 y=7 margin-right=12 spacing=6 align=right end-right="frame_minimize" } + + place { control="AccountButton" width=28 height=28 y=10 margin-right=12 align=right end-right="InboxButton" } + + place { control="frame_captiongrip" margin=2 width=max height=104 } + + region { name="hidden" width=0 height=0 margin-left=-999 } +- place { control="view_friends,fullscreen,startvr,exitvr,add_game,AnnouncementButton,universe_label,EOLAlert" region="hidden" width=0 height=0 } ++ place { control="fullscreen,startvr,exitvr,add_game,AnnouncementButton,universe_label,EOLAlert" region="hidden" width=0 height=0 } + } + } + +--- Adwaita/resource/layout/uistatuspanel.layout ++++ Adwaita/resource/layout/uistatuspanel.layout +@@ -2,6 +2,48 @@ + { + styles + { ++ StatusLabel ++ { ++ inset="0 0 0 0" ++ padding="9 9 9 9" ++ minimum-width=34 ++ minimum-height=34 ++ bgcolor=none ++ textcolor=none ++ font-size=1 ++ image="assets/icons/downloads_backdrop" ++ } ++ StatusLabel:framefocus ++ { ++ image="assets/icons/downloads" ++ } ++ StatusLabel:hover ++ { ++ render_bg ++ { ++ 0="fill(x0+6, y0, x0+28, y0+34, button_hover_bg)" ++ 1="fill(x0, y0+6, x0+6, y0+28, button_hover_bg)" ++ 2="fill(x0+28, y0+6, x0+34, y0+28, button_hover_bg)" ++ 3="image(x0, y0, x0+6, y0+6, assets/corners/6_w15/tl)" ++ 4="image(x0+28, y0, x0+34, y0+6, assets/corners/6_w15/tr)" ++ 5="image(x0, y0+28, x0+6, y0+34, assets/corners/6_w15/bl)" ++ 6="image(x0+28, y0+28, x0+34, y0+34, assets/corners/6_w15/br)" ++ } ++ } ++ StatusLabel:active ++ { ++ render_bg ++ { ++ 0="fill(x0+6, y0, x0+28, y0+34, button_active_bg)" ++ 1="fill(x0, y0+6, x0+6, y0+28, button_active_bg)" ++ 2="fill(x0+28, y0+6, x0+34, y0+28, button_active_bg)" ++ 3="image(x0, y0, x0+6, y0+6, assets/corners/6_w30/tl)" ++ 4="image(x0+28, y0, x0+34, y0+6, assets/corners/6_w30/tr)" ++ 5="image(x0, y0+28, x0+6, y0+34, assets/corners/6_w30/bl)" ++ 6="image(x0+28, y0+28, x0+34, y0+34, assets/corners/6_w30/br)" ++ } ++ } ++ + SlimProgressBar + { + bgcolor=none +@@ -13,9 +55,10 @@ + + layout + { +- place { control="StatusProgressBar" x=0 y=0 width=max height=2 } ++ place { control="StatusDownloading" align=left x=0 y=0 width=34 height=34 } ++ place { control="StatusProgressBar" align=left x=11 y=23 width=12 height=2 } + + region { name="hidden" width=0 height=0 margin-left=-999 } +- place { control="StatusDownloading,StatusPaused,StatusComplete" region="hidden" width=0 height=0 } ++ place { control="StatusPaused,StatusComplete" region="hidden" width=0 height=0 } + } + } diff --git a/extras/patches/headerbar/downloads.patch b/extras/patches/headerbar/downloads.patch new file mode 100644 index 00000000..419cdbef --- /dev/null +++ b/extras/patches/headerbar/downloads.patch @@ -0,0 +1,78 @@ +# Downloads button in the main window headerbar +--- Adwaita/resource/layout/steamrootdialog.layout ++++ Adwaita/resource/layout/steamrootdialog.layout +@@ -6,9 +6,8 @@ + + place { control="frame_title" width=max height=48 } + place { control="UINavigatorPanel" width=max height=max } +- place { control="UIStatusPanel" width=max height=2 y=48 } + +- place { control="InboxButton,SupportAlert,ParentalLockButton,MenuBar" width=34 height=34 y=7 margin-right=12 spacing=6 align=right end-right="frame_minimize" } ++ place { control="InboxButton,SupportAlert,ParentalLockButton,UIStatusPanel,MenuBar" width=34 height=34 y=7 margin-right=12 spacing=6 align=right end-right="frame_minimize" } + + place { control="AccountButton" width=28 height=28 y=10 margin-right=12 align=right end-right="InboxButton" } + +--- Adwaita/resource/layout/uistatuspanel.layout ++++ Adwaita/resource/layout/uistatuspanel.layout +@@ -2,6 +2,48 @@ + { + styles + { ++ StatusLabel ++ { ++ inset="0 0 0 0" ++ padding="9 9 9 9" ++ minimum-width=34 ++ minimum-height=34 ++ bgcolor=none ++ textcolor=none ++ font-size=1 ++ image="assets/icons/downloads_backdrop" ++ } ++ StatusLabel:framefocus ++ { ++ image="assets/icons/downloads" ++ } ++ StatusLabel:hover ++ { ++ render_bg ++ { ++ 0="fill(x0+6, y0, x0+28, y0+34, button_hover_bg)" ++ 1="fill(x0, y0+6, x0+6, y0+28, button_hover_bg)" ++ 2="fill(x0+28, y0+6, x0+34, y0+28, button_hover_bg)" ++ 3="image(x0, y0, x0+6, y0+6, assets/corners/6_w15/tl)" ++ 4="image(x0+28, y0, x0+34, y0+6, assets/corners/6_w15/tr)" ++ 5="image(x0, y0+28, x0+6, y0+34, assets/corners/6_w15/bl)" ++ 6="image(x0+28, y0+28, x0+34, y0+34, assets/corners/6_w15/br)" ++ } ++ } ++ StatusLabel:active ++ { ++ render_bg ++ { ++ 0="fill(x0+6, y0, x0+28, y0+34, button_active_bg)" ++ 1="fill(x0, y0+6, x0+6, y0+28, button_active_bg)" ++ 2="fill(x0+28, y0+6, x0+34, y0+28, button_active_bg)" ++ 3="image(x0, y0, x0+6, y0+6, assets/corners/6_w30/tl)" ++ 4="image(x0+28, y0, x0+34, y0+6, assets/corners/6_w30/tr)" ++ 5="image(x0, y0+28, x0+6, y0+34, assets/corners/6_w30/bl)" ++ 6="image(x0+28, y0+28, x0+34, y0+34, assets/corners/6_w30/br)" ++ } ++ } ++ + SlimProgressBar + { + bgcolor=none +@@ -13,9 +55,10 @@ + + layout + { +- place { control="StatusProgressBar" x=0 y=0 width=max height=2 } ++ place { control="StatusDownloading" align=left x=0 y=0 width=34 height=34 } ++ place { control="StatusProgressBar" align=left x=11 y=23 width=12 height=2 } + + region { name="hidden" width=0 height=0 margin-left=-999 } +- place { control="StatusDownloading,StatusPaused,StatusComplete" region="hidden" width=0 height=0 } ++ place { control="StatusPaused,StatusComplete" region="hidden" width=0 height=0 } + } + } diff --git a/extras/patches/headerbar/friends.patch b/extras/patches/headerbar/friends.patch new file mode 100644 index 00000000..2b15eeef --- /dev/null +++ b/extras/patches/headerbar/friends.patch @@ -0,0 +1,19 @@ +# Friends button in the main window headerbar +--- Adwaita/resource/layout/steamrootdialog.layout ++++ Adwaita/resource/layout/steamrootdialog.layout +@@ -8,13 +8,13 @@ + place { control="UINavigatorPanel" width=max height=max } + place { control="UIStatusPanel" width=max height=2 y=48 } + +- place { control="InboxButton,SupportAlert,ParentalLockButton,MenuBar" width=34 height=34 y=7 margin-right=12 spacing=6 align=right end-right="frame_minimize" } ++ place { control="InboxButton,view_friends,SupportAlert,ParentalLockButton,MenuBar" width=34 height=34 y=7 margin-right=12 spacing=6 align=right end-right="frame_minimize" } + + place { control="AccountButton" width=28 height=28 y=10 margin-right=12 align=right end-right="InboxButton" } + + place { control="frame_captiongrip" margin=2 width=max height=104 } + + region { name="hidden" width=0 height=0 margin-left=-999 } +- place { control="view_friends,fullscreen,startvr,exitvr,add_game,AnnouncementButton,universe_label,EOLAlert" region="hidden" width=0 height=0 } ++ place { control="fullscreen,startvr,exitvr,add_game,AnnouncementButton,universe_label,EOLAlert" region="hidden" width=0 height=0 } + } + }