⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 8.lua

📁 htc manila 2 sourcecode
💻 LUA
字号:
-- Decompiled using luadec 0.4 by sztupy (http://winmo.sztupy.hu)
-- Command line was: -l ;0;0,0,10,14,18;0;0,11,28,42;16;; 22bb3b19_manila_8FBC.luac 

LoadingCount = 0
require("scrollphysics")
ItemSizeWidth = 480
ItemSizeHeight = 81
LVWidth = 480
LVHeight = 636
APNameWidth = 350
ProgramListView_HandleKeyDown = function(l_1_0, l_1_1, l_1_2)
   if l_1_1.Code == KeyCode_Return or l_1_1.Code == KeyCode_Space then
      HandleListSelection(ProgramListView:GetGenerator().SelectedIndex)
      l_1_2.value = true
   end
end

ProgramListView_HandleItemCreated = function(l_2_0, l_2_1)
   trace("Data:GetName()" .. l_2_0:GetName())
   local l_2_2 = l_2_1.Namespace:FindName("ProgramListIcon")
   local l_2_3 = l_2_1.Namespace:FindName("ProgramListItemText")
   local l_2_4 = l_2_1.Namespace:FindName("DottedLine")
   l_2_2._visible = false
   if l_2_0:GetName() ~= "" then
      l_2_3.String = l_2_0:GetName()
      if ListImageLoader == nil then
         ListImageLoader = ListImageLoaderClass()
      end
      ListImageLoader:AddImage(l_2_2, l_2_0)
      l_2_3.Size.width = APNameWidth
   end
   l_2_2.Position.y = -(ItemSizeHeight - l_2_2.Size.height) / 2
   l_2_3.Position.y = -(ItemSizeHeight - l_2_3.Size.height) / 2
   l_2_4.Size.width = ItemSizeWidth
   l_2_4.TextureCoords:set(0, 0, ItemSizeWidth / 2, 1)
   l_2_4.Position.y = -(ItemSizeHeight - 1)
   l_2_1.Focusable = true
   l_2_1.onKeyDown:connect(ProgramListView_HandleKeyDown)
end

ProgramListView_HandleItemDestroyed = function(l_3_0)
   trace("HandleItemDestroyed")
end

HandleListSelection = function(l_4_0)
   trace("HandleListSelection" .. tostring(l_4_0))
   local l_4_1 = ProgramListcollection:GetItem(l_4_0)
   if l_4_1:GetName() ~= "" then
      if _application.Store:GetIntValue(Lifetime_Application, "Programs.ImmediateLaunch") == 1 then
         l_4_1:Launch()
      else
         local l_4_2 = CompositeItem()
         l_4_2:SetPath(l_4_1:GetPath())
         l_4_2:SetName(l_4_1:GetName())
         local l_4_3 = _application.Store:GetIntValue(Lifetime_Application, "Programs.ActiveIndex")
         l_4_2:SetIndex(l_4_3)
         CompositeManager_Instance():Update(l_4_2)
         _application.Store:SetIntValue(Lifetime_Application, "Programs.FocusIndex", l_4_3 + 1)
      end
      PageChange()
   end
end

StartProgramListPage = function()
   trace("StartProgramListPage")
   ProgramListView.Viewport.x = LVWidth
   ProgramListView.Viewport.y = LVHeight
   CubePage_ItemListLayout = TileLayout()
   local l_5_0 = Vector3F()
   l_5_0.x = ItemSizeWidth
   l_5_0.y = ItemSizeHeight
   l_5_0.z = 0
   CubePage_ItemListLayout.SelectionNode = ProgramListPickerSelector
   CubePage_ItemListLayout.ItemSize = l_5_0
   ProgramListView:SetLayout(CubePage_ItemListLayout)
   ProgramListcollection = ProgramFolderManager_Instance():GetLaunchItems()
   CubePage_ItemListGenerator = ProgramFolderLibraryGenerator(ProgramListcollection, ProgramListView:GetMovie(), ProgramListView.ComponentLibraryName, ProgramListView.ComponentLibraryID)
   CubePage_ItemListGenerator.RecycleItems = true
   CubePage_ItemListGenerator.ItemCreated:connect(ProgramListView_HandleItemCreated)
   CubePage_ItemListGenerator.ItemDestroyed:connect(ProgramListView_HandleItemDestroyed)
   ProgramListView:SetGenerator(CubePage_ItemListGenerator)
   ListPhysics = ScrollPhysics(ProgramListView, ProgramListView, HandleListSelection)
   ListPhysics:ConnectMouseEvents()
   ProgramListView:ForceLayout()
   ProgramListView:Focus()
   ProgramListView._visible = true
end

if _application.Store:GetStringValue(Lifetime_Permanent, "EnableLandscape") == "true" then
   trace("[ProgramList] : EnableLandscape")
   require("Programs\\ProgramList_Landscape")
   _ProgramList_ScreenRotation = ProgramList_ScreenRotation()
end
if DataBindingEnabled then
   StartProgramListPage()
end
HandleVisibilityChanged = function()
   if _application.Visibility then
      ListPhysics:ConnectMouseEvents()
   else
      ListPhysics:DisconnectMouseEvents()
   end
end

_application.OnVisibilityChanged:connect(HandleVisibilityChanged)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -