File tree 4 files changed +17
-3
lines changed
4 files changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ There are 4 files:
13
13
- ` Style.css ` : Your custom CSS code to insert
14
14
15
15
Write your Steam installation path in ` SteamPath.txt ` and custom CSS code in ` Style.css ` .
16
+ Optionally, you can create an extra ` BrowserStyle.css ` file. This style will be inserted to Steam Browser styles in replace of ` Style.css ` .
16
17
17
18
Start ` SteamCSS.exe ` to run the program.
18
19
Original file line number Diff line number Diff line change 13
13
- ` Style.css ` : 自定义要插入的 CSS 代码
14
14
15
15
先在 ` SteamPath.txt ` 里写下 Steam 的安装文件夹, ` Style.css ` 里写下要插入的 CSS 代码.
16
+ 另外也可以再新建一个 ` BrowserStyle.css ` 文件, 这个样式可以替代 ` Style.css ` 插入到 Steam 内置浏览器的样式中.
16
17
17
18
然后启动 ` SteamCSS.exe ` 就可以了.
18
19
Original file line number Diff line number Diff line change @@ -37,7 +37,18 @@ static void Main()
37
37
try
38
38
{
39
39
var steamPath = File . ReadAllText ( "SteamPath.txt" ) . Trim ( ) ;
40
- var style = File . ReadAllText ( "Style.css" ) ;
40
+ var mainStyle = File . ReadAllText ( "Style.css" ) ;
41
+
42
+ var browserStyle = "" ;
43
+ if ( File . Exists ( "BrowserStyle.css" ) )
44
+ {
45
+ browserStyle = File . ReadAllText ( "BrowserStyle.css" ) ;
46
+ }
47
+ else
48
+ {
49
+ browserStyle = mainStyle ;
50
+ }
51
+
41
52
var cssFiles = File . ReadAllText ( "StylePath.txt" ) . Trim ( ) . Split ( new string [ ] { Environment . NewLine } , StringSplitOptions . RemoveEmptyEntries ) . ToList ( ) ;
42
53
var processedFiles = new List < string > ( ) ;
43
54
cssFiles . ForEach ( file =>
@@ -48,6 +59,7 @@ static void Main()
48
59
return ;
49
60
}
50
61
var content = File . ReadAllText ( filePath ) ;
62
+ var style = file . Contains ( "webkit" ) ? browserStyle : mainStyle ;
51
63
if ( ! content . StartsWith ( style ) )
52
64
{
53
65
File . WriteAllText ( filePath , style + Environment . NewLine + content ) ;
Original file line number Diff line number Diff line change 32
32
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
33
33
//通过使用 "*",如下所示:
34
34
// [assembly: AssemblyVersion("1.0.*")]
35
- [ assembly: AssemblyVersion ( "1.0.1 .0" ) ]
36
- [ assembly: AssemblyFileVersion ( "1.0.1 .0" ) ]
35
+ [ assembly: AssemblyVersion ( "1.1.0 .0" ) ]
36
+ [ assembly: AssemblyFileVersion ( "1.1.0 .0" ) ]
You can’t perform that action at this time.
0 commit comments