Skip to content

Commit

Permalink
Additional patches to show more headerbar buttons
Browse files Browse the repository at this point in the history
  • Loading branch information
tkashkin committed Apr 2, 2023
1 parent 341aa37 commit 5a64ac1
Show file tree
Hide file tree
Showing 4 changed files with 184 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Adwaita/resource/menus/steam.menu
Original file line number Diff line number Diff line change
Expand Up @@ -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 {}

Expand Down
86 changes: 86 additions & 0 deletions extras/patches/headerbar/all.patch
Original file line number Diff line number Diff line change
@@ -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 }
}
}
78 changes: 78 additions & 0 deletions extras/patches/headerbar/downloads.patch
Original file line number Diff line number Diff line change
@@ -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 }
}
}
19 changes: 19 additions & 0 deletions extras/patches/headerbar/friends.patch
Original file line number Diff line number Diff line change
@@ -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 }
}
}

0 comments on commit 5a64ac1

Please sign in to comment.