Windows 8 Build 7776.0.fbl grfx dev1.100708-1700:修订间差异

第 184 行: 第 184 行:
</syntaxhighlight>
</syntaxhighlight>


==== Functionality ====
==== 功能 ====
Links to several work-in-progress pages, like for the "What's fresh", "Results" and "Product Description Page" (PDP) pages, are present inside the application's code. All of these pages would query an internal <code><nowiki>http://paulke86-srv/winstore/win8/usa/en-us/ms/non-touch</nowiki></code> server that would show the page's user interface in a <code>.htm</code> file. The only file that does not contact this server is the <code>offline.htm</code> file, which, as indicated by the name, is the file that shows when the internal Windows Store server cannot be communicated to. This file is meant to be displayed at <code>1366x768</code> resolution, although not all of the file's content will be shown properly at that resolution. Setting the display resolution to a less conventional <code>1384x824</code> resolution will allow the Store to show all of its content as presumably intended. 
应用的代码中包含指向多个正在制作中的页面的链接,例如“What's fresh”“Results”和“Product Description Page”(PDP)页面。这些页面都会向一个内部服务器 <code><nowiki>http://paulke86-srv/winstore/win8/usa/en-us/ms/non-touch</nowiki></code> 发送请求,从而在 <code>.htm</code> 文件中显示页面的用户界面。唯一不联系此服务器的文件是 <code>offline.htm</code> 文件,顾名思义,当无法与内部 Windows 应用商店服务器通信时,此文件会显示。此文件设计用于 <code>1366×768</code> 分辨率(由于应用的滚动条,“X”按钮会被遮挡),将文件设置为更高分辨率时,未使用区域会显示深灰色背景。


The Windows Store executable can accept three arguments - <code>/purchase <product GUID></code>, <code>/product <product GUID></code> and <code>/search <query></code> (these can additionally be spelled with a dash instead of a slash). If Windows Store is launched without any arguments, the Store will attempt to open the "What's fresh" (<code>whats-fresh.htm</code>) page located on the <code>paulke86-srv</code> internal server. If the <code>/search</code> argument is used, the Store will attempt to open the Results page with the user's inputted query (<code>results.htm?query=<query></code>), and if the <code>/product</code> argument is used, the Store will attempt to open the application's Product Display Page via the "What's fresh" <code>.htm</code> file (<code>whats-fresh.htm?pdp=<GUID></code>). Attempting to use the <code>/purchase</code> argument will cause Windows Store to perform no action and simply not launch due to the argument returning <code>[https://learn.microsoft.com/en-us/dotnet/api/microsoft.visualstudio.vsconstants.e_notimpl?view=visualstudiosdk-2022 E_NOTIMPL]</code>
Windows 应用商店可执行文件可以接受三个参数 - <code>/purchase <产品 GUID></code><code>/product <产品 GUID></code> <code>/search <查询></code>(这些参数也可以用破折号代替斜杠)。如果 Windows 应用商店在没有任何参数的情况下启动,应用商店将尝试打开位于 <code>paulke86-srv</code> 内部服务器的“What's fresh”(<code>whats-fresh.htm</code>)页面。如果使用 <code>/search</code> 参数,应用商店将尝试使用用户输入的查询打开结果页面(<code>results.htm?query=<query></code>);如果使用 <code>/product</code> 参数,应用商店将尝试通过“What's fresh”<code>.htm</code> 文件(<code>whats-fresh.htm?pdp=<GUID></code>)打开应用的产品展示页面。尝试使用 <code>/purchase</code> 参数将导致 Windows 应用商店不执行任何操作,且由于此参数返回 <code>[https://learn.microsoft.com/en-us/dotnet/api/microsoft.visualstudio.vsconstants.e_notimpl?view=visualstudiosdk-2022 E_NOTIMPL]</code> 而无法启动。


Similarly to the <code>.htm</code> pages, hardcoded dummy data for Windows Store product information depicting a [[w:crossword|crossword]] video game can be found inside the code as well - this application would have taken its Windows Store resources from the same server as the aforementioned pages. The description of the fake app is a direct copy of the lead section of the [[w:Special:PermanentLink/369161122|then-latest revision of the Crossword article]] on the English Wikipedia, and the rest of the info shows the apparent size, version, price, language and release date of the app.
<code>.htm</code> 页面类似,Windows 应用商店产品信息的硬编码虚拟数据也可以在代码中找到,这些数据描绘了一个名为“Crossword Magic”的填字游戏应用——此应用本应从与前述页面相同的服务器获取其 Windows 应用商店资源。此伪应用的描述是直接复制自当时英语维基百科 Crossword 条目的最新修订版本的开头部分,其余信息显示了应用的显著大小、版本、价格、语言和发布日期。


On startup, the application checks for the presence of a <code>RemoveWindowsStore</code> DWORD in the <code>HKLM\Software\Policies\Microsoft\WindowsStore</code> and <code>HKCU\Software\Policies\Microsoft\WindowsStore</code> directories. If the DWORD is set to 1, the application will instead display the <code>offline.htm?id=3</code> string instead of simply <code>offline.htm</code>, resulting in the following message in place of the cannot connect one: "The Windows Store is disabled. Contact your system administrator about enabling the Windows Store.". Equivalently, a <code>offline.htm?id=4</code> string exists as well, but is never called, and reads: "The Windows Store is unavailable in this location.".
在启动时,此应用会检查 <code>HKLM\Software\Policies\Microsoft\WindowsStore</code> <code>HKCU\Software\Policies\Microsoft\WindowsStore</code> 目录中是否存在 <code>RemoveWindowsStore</code> DWORD。如果此 DWORD 设置为 1,应用将显示 <code>offline.htm?id=3</code> 字符串,而不是简单地显示 <code>offline.htm</code>,从而在“无法连接”消息的位置显示以下信息:“Windows 应用商店已被禁用。请联系系统管理员以启用 Windows 应用商店。” 同样,也存在一个 <code>offline.htm?id=4</code> 字符串,但从未被调用,其内容为:“此位置的 Windows 应用商店不可用。”
<gallery>
<gallery>
File:Win8-7776-WindowsStore.png|Windows Store at <code>1366x768</code> resolution
Win8-7776-WindowsStore.png|分辨率为 <code>1366×768</code> 的 Windows 应用商店
File:Win8-7776-WindowsStore3.png|Ditto, at <code>1384x824</code> resolution
Win8-7776-WindowsStore3.png|同上一个,分辨率为 <code>1384×824</code>
File:Win8-7776-WindowsStore2.png|Ditto, with <code>RemoveWindowsStore</code> DWORD set to 1  
Win8-7776-WindowsStore2.png|同上一个,<code>RemoveWindowsStore</code> DWORD 设置为 1
</gallery>
</gallery>