peopleemailsetup.luac.lua
来自「htc manila 2 sourcecode」· LUA 代码 · 共 104 行
LUA
104 行
-- Decompiled using luadec 0.7 by sztupy (http://winmo.sztupy.hu)
-- Command line was: -l ;;;;;;;;;0,0,1,2,3,4,5; 74e9c739_manila.luac
require("contacts_database_svc")
require("transitions")
require("People\\PeopleSIMDialog")
main = function()
objs3D = {}
objs3D[1] = Camera3D
_request.NavigateOutTo:connect(OnNavigateOut)
_request.NavigateInFrom:connect(OnNavigateIn)
_application:SetLeftSoftkey(Softkey(Locale:GetString("IDS_OK"), LSKFunction_Callback))
_application:SetRightSoftkey(Softkey(Locale:GetString("IDS_CANCEL"), RSKFunction_Callback))
InputBoxTitle.String = Locale:GetString("IDS_EMAIL_ADDRESS") .. ":"
AddressInputBox.onPress:connect(AddressInputBox_onPress)
AddressInputBox.onFocusOut:connect(AddressInputBox_FocusOut)
if _application.Store:GetStringValue(Lifetime_Permanent, "EnableLandscape") == "true" then
trace("[peopleEmail] : EnableLandscape")
require("people\\peopleEmail_Landscape")
PeopleEmail_Landscape = PeopleEmail_ScreenRotation(ResetScreenLayout)
else
ResetScreenLayout(480, 696)
end
end
OnNavigateOut = function(l_2_0)
_request.NavigateOutTo:disconnect(OnNavigateOut)
_application:EnableVelocityEngine(true)
AddressInputBox:SetWindowSize(0, 0)
AddressInputBox._visible = false
Transition(l_2_0, "Out")
AddressInputBox:SetShowWindowFlag(false)
end
OnNavigateIn = function(l_3_0)
_request.NavigateInFrom:disconnect(OnNavigateIn)
Transition(l_3_0, "In")
_application:EnableVelocityEngine(false)
_application:ShowInputPanel(0)
AddressInputBox:SetShowWindowFlag(true)
end
RSKFunction_Callback = function()
_application.Navigation:NavigateBack()
end
IsInVaildInput = function(l_5_0)
if l_5_0 == nil then
return true
else
if l_5_0:len() == 0 then
return true
end
end
return false
end
LSKFunction_Callback = function()
local l_6_0 = AddressInputBox.WindowText
if IsInVaildInput(l_6_0) then
AddressInputBox:SetShowWindowFlag(false)
ShowInputEmptyDialog()
return
end
_application.Navigation:NavigateBack()
trace("[PeopleEmailSetup] LSKFunction_Callback, Email address: " .. tostring(l_6_0) .. ", length: " .. tostring(l_6_0:len()))
local pei = PeopleEngine_Instance()
local pi = PersonInfo()
pei:GetPersonInfo(pi)
pi:SetEmailAddress(l_6_0)
end
AddressInputBox_onPress = function(l_7_0, l_7_1)
_application:ShowInputPanel(0)
l_7_0:SetShowWindowFlag(true)
l_7_0:Focus()
end
AddressInputBox_FocusOut = function()
_application:HideInputPanel()
end
ResetScreenLayout = function(l_9_0, l_9_1)
local l_9_2 = 15
local l_9_3 = 60
local l_9_4 = 10
local l_9_5 = 25
local l_9_6 = -125
local l_9_7 = 60
local l_9_8 = -l_9_0 / 2
local l_9_9 = l_9_1 / 2 - l_9_7
InputBoxTitle.Position.x = l_9_8 + l_9_2
InputBoxTitle.Position.y = l_9_9 - l_9_4
AddressInputBox:SetWindowSize(l_9_0 - l_9_5 * 2, 35)
trace("AddressInputBox pos=" .. AddressInputBox.Position.x .. " x " .. AddressInputBox.Position.y)
InputAssets.Position.x = l_9_8 + l_9_2
InputAssets.Position.y = l_9_9 - l_9_3
InputAssets.Size.width = l_9_0 - l_9_2 * 2
AddressInputBox:Focus()
end
main()
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?