-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathCustom.xaml
174 lines (171 loc) · 16.3 KB
/
Custom.xaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
<!--
____ ___
/\ _`\ __ /\_ \ /'\_/`\ __
\ \,\L\_\/\_\ ___ ___ _____\//\ \ __ /\ \ __ /\_\ ___ _____ __ __ __
\/_\__ \\/\ \ /' __` __`\/\ '__`\\ \ \ /'__`\ \ \ \__\ \ /'__`\ \/\ \ /' _ `\/\ '__`\ /'__`\ /'_ `\ /'__`\
/\ \L\ \ \ \/\ \/\ \/\ \ \ \L\ \\_\ \_/\ __/ \ \ \_/\ \/\ \L\.\_\ \ \/\ \/\ \ \ \L\ \/\ \L\.\_/\ \L\ \/\ __/
\ `\____\ \_\ \_\ \_\ \_\ \ ,__//\____\ \____\ \ \_\\ \_\ \__/.\_\\ \_\ \_\ \_\ \ ,__/\ \__/.\_\ \____ \ \____\
\/_____/\/_/\/_/\/_/\/_/\ \ \/ \/____/\/____/ \/_/ \/_/\/__/\/_/ \/_/\/_/\/_/\ \ \/ \/__/\/_/\/___L\ \/____/
\ \_\ \ \_\ /\____/
\/_/ \/_/ \_/__/
\- by MFn -\
\- https://github.com/MFn233/PCL-Mainpage -\
-->
<local:MyCard Margin="0,0,0,12" Title="欢迎页" CanSwap="True" IsSwaped="False">
<StackPanel Margin="24,40,24,15">
<TextBlock HorizontalAlignment="Center" Margin="0,0,0,12" Foreground="{DynamicResource ColorBrush2}" FontSize="20"
Text="欢迎使用Simple Mainpage!" />
<!-- <local:MyHint Text="主页作者: MFn233" Margin="0,0,0,0" Padding="0,2,0,2" IsWarn="False" /> -->
<!--这玩意可以不用放了-->
<Calendar HorizontalAlignment="Center" Margin="0,12,0,10" Grid.Column="0"/>
<!--因为“你知道吗”在启动游戏的时候会出现,所以我只在这里设置了回声洞-->
<TextBlock Margin="5,0,5,12" TextWrapping="Wrap" HorizontalAlignment="Center" Foreground="{DynamicResource ColorBrush1}" Text="{cave}" />
<Grid >
<Grid.ColumnDefinitions>
<ColumnDefinition Width="5*" />
<ColumnDefinition Width="0.3*" />
<ColumnDefinition Width="0.5*" />
</Grid.ColumnDefinitions>
<local:MyIconButton Grid.Column="1" LogoScale="1.2" Logo="M13.5,4A1.5,1.5 0 0,0 12,5.5A1.5,1.5 0 0,0 13.5,7A1.5,1.5 0 0,0 15,5.5A1.5,1.5 0 0,0 13.5,4M13.14,8.77C11.95,8.87 8.7,11.46 8.7,11.46C8.5,11.61 8.56,11.6 8.72,11.88C8.88,12.15 8.86,12.17 9.05,12.04C9.25,11.91 9.58,11.7 10.13,11.36C12.25,10 10.47,13.14 9.56,18.43C9.2,21.05 11.56,19.7 12.17,19.3C12.77,18.91 14.38,17.8 14.54,17.69C14.76,17.54 14.6,17.42 14.43,17.17C14.31,17 14.19,17.12 14.19,17.12C13.54,17.55 12.35,18.45 12.19,17.88C12,17.31 13.22,13.4 13.89,10.71C14,10.07 14.3,8.67 13.14,8.77Z"
Height="21" Margin="0,5,0,0"
ToolTip="Minecraft新闻(作者:最亮的信标)" EventData="https://news.bugjump.net/News.json" EventType="打开帮助" VerticalAlignment="Bottom"/>
<local:MyIconButton Grid.Column="2" LogoScale="1.2" Logo="M256.455,8C322.724,8.119,382.892,34.233,427.314,76.685L463.029,40.97C478.149,25.851,504,36.559,504,57.941L504,192C504,205.255,493.255,216,480,216L345.941,216C324.559,216,313.851,190.149,328.97,175.029L370.72,133.279C339.856,104.38 299.919,88.372 257.49,88.006 165.092,87.208 87.207,161.983 88.0059999999999,257.448 88.764,348.009 162.184,424 256,424 297.127,424 335.997,409.322 366.629,382.444 371.372,378.283 378.535,378.536 382.997,382.997L422.659,422.659C427.531,427.531 427.29,435.474 422.177,440.092 378.202,479.813 319.926,504 256,504 119.034,504 8.001,392.967 8,256.002 7.999,119.193 119.646,7.755 256.455,8z"
Height="21" Margin="0,5,0,0"
ToolTip="点此刷新" EventData="回声洞" EventType="刷新主页" VerticalAlignment="Bottom"/>
</Grid>
<!-- <local:MyButton Margin="0,-10,-5,0" Width="15" Height="15" HorizontalAlignment="Right" ToolTip="刷新" EventType="刷新主页" EventData="回声洞">
<Path Fill="{DynamicResource ColorBrush5}" Stretch="Fill" Width="15" Height="15">
<Path.Data>
<PathGeometry FillRule="Nonzero" Figures="M256.455,8C322.724,8.119,382.892,34.233,427.314,76.685L463.029,40.97C478.149,25.851,504,36.559,504,57.941L504,192C504,205.255,493.255,216,480,216L345.941,216C324.559,216,313.851,190.149,328.97,175.029L370.72,133.279C339.856,104.38 299.919,88.372 257.49,88.006 165.092,87.208 87.207,161.983 88.0059999999999,257.448 88.764,348.009 162.184,424 256,424 297.127,424 335.997,409.322 366.629,382.444 371.372,378.283 378.535,378.536 382.997,382.997L422.659,422.659C427.531,427.531 427.29,435.474 422.177,440.092 378.202,479.813 319.926,504 256,504 119.034,504 8.001,392.967 8,256.002 7.999,119.193 119.646,7.755 256.455,8z"/>
</Path.Data>
</Path>
</local:MyButton> -->
<!--
网上随便抄来的刷新按钮。。。因为path不会画
这是旧的刷新主页按钮设计,现在我改成了local:myiconbutton
-->
</StackPanel>
</local:MyCard>
<local:MyCard Margin="0,0,0,12" Title="网页捷径" CanSwap="True" IsSwaped="True">
<StackPanel Margin="20,40,20,15">
<!-- 尝试做了一下,输入网页,按按钮打开。这将会加入V0.0.5中。 -->
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="3*" />
<ColumnDefinition Width="1*" />
</Grid.ColumnDefinitions>
<local:MyTextBox Margin="0,0,0,10" Name="site" Height="30" Grid.Column="0"/>
<local:MyButton EventType="打开网页" EventData="{Binding ElementName=site,Path=Text}" Text="打开网页" Margin="5,0,0,10" Height="30" Grid.Column="1" Padding="2,0,2,0" ColorType="Highlight"/>
</Grid>
<local:MyCard Margin="0,0,0,6" Title="常用网站" CanSwap="True" IsSwaped="False">
<StackPanel Margin="24,40,24,15">
<local:MyListItem Margin="-2,0,0,0" Logo="https://www.baidu.com/favicon.ico" Title="百度" Info="百度一下,你就知道" EventType="打开网页" EventData="https://www.baidu.com/" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://cn.bing.com/favicon.ico" Title="Bing" Info="有求必应" EventType="打开网页" EventData="https://cn.bing.com/" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://www.bilibili.com/favicon.ico" Title="Bilibili" Info="哔哩哔哩 (゜-゜)つロ 干杯~" EventType="打开网页" EventData="https://www.bilibili.com/" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://github.githubassets.com/favicon.ico" Title="GitHub" Info="Let's build from here" EventType="打开网页" EventData="https://github.com/" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://static.zhihu.com/heifetz/favicon.ico" Title="知乎" Info="有问题,就会有答案" EventType="打开网页" EventData="https://www.zhihu.com/" Type="Clickable" />
</StackPanel>
</local:MyCard>
<local:MyCard Margin="0,0,0,12" Title="Minecraft相关" CanSwap="True" IsSwaped="True">
<StackPanel Margin="24,40,24,15">
<local:MyListItem Margin="-2,0,0,0" Logo="pack://application:,,,/images/Blocks/Grass.png"
Title="Minecraft官网" Info="Minecraft国际版官网" EventType="打开网页" EventData="https://www.minecraft.net" Type="Clickable" />
<!-- 藏得很隐蔽。。
https://www.minecraft.net/etc.clientlibs/minecraft/clientlibs/main/resources/favicon.ico
但是加载不出来
-->
<local:MyListItem Margin="-2,0,0,0" Logo="pack://application:,,,/images/Blocks/Grass.png" Title="网易我的世界官网" Info="我的世界中国版官网" EventType="打开网页" EventData="https://mc.163.com/" Type="Clickable" />
<!-- https://mc.163.com/favicon.ico
太低清。。
-->
<local:MyListItem Margin="-2,0,0,0" Logo="pack://application:,,,/images/Blocks/GrassPath.png" Title="MCBBS" Info="最大的我的世界《Minecraft》中文论坛" EventType="打开网页" EventData="https://www.mcbbs.net" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://klpbbs.com/favicon.ico" Title="苦力怕BBS" Info="最大的我的世界《Minecraft》基岩版(BE)中文资源、交流论坛之一" EventType="打开网页" EventData="https://klpbbs.com/" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://www.minebbs.com/favicon.ico" Title="MineBBS" Info="以我的世界基岩版(MCBE)内容为主的Minecraft中文论坛。" EventType="打开网页" EventData="https://www.minebbs.com/" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://www.mcmod.cn/favicon.ico" Title="MC百科" Info="最大的Minecraft中文Mod百科" EventType="打开网页" EventData="https://www.mcmod.cn/" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://zh.minecraft.wiki/favicon.ico" Title="中文Minecraft Wiki" Info="最详细的我的世界百科" EventType="打开网页" EventData="https://zh.minecraft.wiki/" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://static-beta.curseforge.com/images/favicon.ico" Title="Curseforge" Info="The Home for the Best Minecraft Mods" EventType="打开网页" EventData="https://www.curseforge.com/minecraft" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://modrinth.com/favicon.ico" Title="Modrinth" Info="Discover, play, and share Minecraft content through our open-source platform built for the community." EventType="打开网页" EventData="https://modrinth.com/" Type="Clickable" />
<local:MyListItem Margin="-2,0,0,0" Logo="https://mcpedl.com/favicon.ico" Title="MCPEDL" Info="Minecraft PE Mods, Maps, Skins, Seeds, Texture Packs" EventType="打开网页" EventData="https://mcpedl.com/" Type="Clickable" />
</StackPanel>
</local:MyCard>
</StackPanel>
</local:MyCard>
<local:MyCard Margin="0,0,0,12" Title="启动器工具" CanSwap="True" IsSwaped="True">
<StackPanel Margin="24,40,24,15">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*" />
<ColumnDefinition Width="1*" />
</Grid.ColumnDefinitions>
<local:MyButton Grid.Column="0" Margin="0,0,10,0" Height="35" Text="打开 PCL 日志" EventType="打开文件" EventData="Log1.txt" ToolTip="查看当前PCL启动器的日志文件。"/>
<local:MyButton Grid.Column="1" Margin="0,0,0,0" Height="35" Text="清理垃圾" EventType="清理垃圾" ToolTip="清理垃圾文件。"/>
</Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*" />
<ColumnDefinition Width="1*" />
</Grid.ColumnDefinitions>
<local:MyButton Grid.Column="0" Margin="0,10,10,0" Height="35" Text="内存优化" EventType="内存优化" ToolTip="将物理内存占用降低约1/3,不仅限于MC!
如果使用机械硬盘,这可能会导致一小段时间的严重卡顿。"/>
<local:MyButton Grid.Column="1" Margin="0,10,0,0" Height="35" Text="定位游戏启动脚本" EventType="打开文件" EventData="explorer.exe|/select,LatestLaunch.bat" ToolTip="打开PCL上一次启动 MC 的脚本(LatestLaunch.bat)。" />
</Grid>
</StackPanel>
</local:MyCard>
<local:MyCard Margin="0,0,0,12" Title="下载器" CanSwap="True" IsSwaped="True">
<StackPanel Margin="24,40,24,15">
<local:MyHint Margin="0,0,0,10" IsWarn="True" Text="链接必须为以http://或https://开头的网址,部分网址可能无法下载" />
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*" />
<ColumnDefinition Width="3*" />
<ColumnDefinition Width="1*" />
</Grid.ColumnDefinitions>
<TextBlock Margin="0,7,0,0" Text="下载链接:" Grid.Column="0" FontSize="13"/>
<local:MyTextBox Margin="-5,0,0,0" Name="web" Height="30" Grid.Column="1"/>
<local:MyButton EventType="下载文件" EventData="{Binding ElementName=web,Path=Text}" Text="开始下载" Margin="5,0,0,0" Height="30" Grid.Column="2" Padding="2,0,2,0" ColorType="Highlight"/>
</Grid>
</StackPanel>
</local:MyCard>
<local:MyCard Margin="0,0,0,12" Title="杂项" CanSwap="True" IsSwaped="True">
<StackPanel Margin="24,40,24,15">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*" />
<ColumnDefinition Width="1*" />
</Grid.ColumnDefinitions>
<local:MyButton Grid.Column="0" Margin="0,0,10,0" Height="35" Text="今日人品" EventType="今日人品"/>
<!--
<local:MyButton Grid.Column="1" Margin="0,0,0,0" Height="35" Text="二次元图" EventType="打开网页" EventData=""/>
龙猫为了让我删掉这个功能甚至发了个issue,因为它会刷r18图
虽然我没刷出来过,不过还是删掉为好吧
或许我会找其他正常点的api替代,也或许以后都不会再有了
api: https://www.loliapi.com/
-->
<local:MyButton Grid.Column="1" Margin="0,0,0,0" Text="启动Minecraft基岩版" EventType="打开网页" EventData="minecraft://" ToolTip="如果你的电脑上安装了Minecraft基岩版,按下这个按钮将会以URL Scheme的方式启动它。" />
<!-- 别不信,真有效
原理是通过url scheme
其实不是什么很深奥的玩意-->
</Grid>
</StackPanel>
</local:MyCard>
<local:MyCard Margin="0,0,0,12" Title="关于" CanSwap="True" IsSwaped="True">
<StackPanel Margin="24,40,24,15">
<local:MyListItem Margin="-2,0,0,12" Logo="https://zh.minecraft.wiki/favicon.ico" Title="【重要!】中文MC Wiki迁移通知" Info="中文MinecraftWiki现已迁移至zh.minecraft.wiki,请不要再访问旧的网站!" EventType="打开网页" EventData="https://zh.minecraft.wiki/w/Minecraft_Wiki:%E8%BF%81%E7%A7%BB%E9%80%9A%E7%9F%A5" Type="Clickable" />
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*" />
<ColumnDefinition Width="1*" />
</Grid.ColumnDefinitions>
<local:MyButton Grid.Column="0" Margin="0,0,10,0" Height="35" Text="关于作者" EventType="弹出窗口"
EventData="关于作者|我是MFn233,一个妄图写出完美代码的程序员,该主页目前由我独立完成,并在GitHub上开源。欢迎你前往仓库为我的项目提issue\n\n如果你真的很希望更多地了解我,欢迎访问我的网站: mfn233.github.io\n\n鸣谢:\nMCSteve123(GitHub)提供增加Minecraft相关网页捷径的建议\nJingHai-Lingyun(GitHub)提供修复建议与改进建议\nSIPC(sipc.ink)帮助将主页文件挂载于云服务器\n\n©MFn233 2023/7/22"/>
<local:MyButton Grid.Column="1" Margin="0,0,0,0" Height="35" Text="项目仓库" EventType="打开网页" EventData="https://github.com/MFn233/PCL-Mainpage"/>
</Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*" />
<ColumnDefinition Width="1*" />
</Grid.ColumnDefinitions>
<local:MyButton Grid.Column="0" Margin="0,10,10,0" Height="35" Text="更新日志" EventType="打开网页"
EventData="https://github.com/MFn233/PCL-Mainpage/releases/latest" ToolTip="将前往GitHub查看最新版本更新日志"/>
</Grid>
</StackPanel>
</local:MyCard>