Advertisement
Guest User

Main.lua

a guest
Feb 22nd, 2018
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.08 KB | None | 0 0
  1. local GUI =  require("GUI")
  2. local image =  require("image")
  3. local buffer = require("doubleBuffering")
  4. local MineOSInterface = require("MineOSInterface")
  5.  
  6. local mainContainer, window = MineOSInterface.addWindow (MineOSInterface.tabbedWindow (1, 1, 88, 25))
  7. window.tabBar:addItem("Applications")
  8. window.tabBar:addItem("About")
  9.  
  10. function debugObject(t)
  11.   for k,v in pairs(t) do
  12.     print(k, v)
  13.   end
  14. end
  15.  
  16. --debugObject(window)
  17.  
  18. local icon = image.load("/MineOS/Applications/Installer.app/Resources/Installer.pic")
  19.  
  20. window:addChild(GUI.image(window.width / 2 - icon[1] / 2, 2, icon))
  21.  
  22. local aboutText = "Installer v0.1 made by StrangeOne101, Feb 2018\nMade to install apps that are no longer avaliable on the App Market. Some may not be translated into English."
  23.  
  24. --Add the about label
  25. window:addChild(GUI.label(window.width / 2, 2 + 4 + icon[2], window.width - 20, 10, 0xFFFFFF, aboutText)):setAlignment (GUI. alignment . horizontal . center , GUI. alignment . vertical . center)
  26.  
  27. function addProgram(name, x, y, url)
  28.  
  29. end
  30.  
  31.  
  32. mainContainer: draw ()
  33. buffer. draw ( true )
  34. mainContainer: startEventHandling ()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement