Advertisement
Guest User

Untitled

a guest
Sep 19th, 2017
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.98 KB | None | 0 0
  1. // this sets the background color of the master UIView (when there are no windows/tab groups on it)
  2. Titanium.UI.setBackgroundColor('#61b2b5');
  3.  
  4. //Include app header
  5. Titanium.include('header.js');
  6.  
  7. var roundedBorder = Titanium.UI.createView({ //rounded top bdr unable to use bg-repeat x
  8.  
  9. width:768,
  10. height:9,
  11. backgroundImage:'images/bdr2.png',
  12. top:160
  13.  
  14. });
  15.  
  16. var viewContainer = Titanium.UI.createView({ //container for buttons
  17. width:768,
  18. height:80,
  19. backgroundColor:'#FFFFFF',
  20. top:165
  21. });
  22.  
  23. var budget = Titanium.UI.createButton({ //popover button 1
  24. backgroundImage:'images/budgetbtn.png',
  25. width:151,
  26. height:43,
  27. left:60,
  28. top:20,
  29. opacity:1
  30. });
  31.  
  32. var room = Titanium.UI.createButton({ //popover button 2
  33. backgroundImage:'images/roombtn.png',
  34. width:74,
  35. height:43,
  36. left:240,
  37. top:20,
  38. opacity:1
  39. });
  40.  
  41. var viewBdr = Titanium.UI.createView({ //goes underneath viewContainer
  42. backgroundImage: 'images/bdr3.png',
  43. width:768,
  44. height:9,
  45. top:230
  46. });
  47.  
  48. var picContainer = Titanium.UI.createView({ //container for buttons
  49. width:768,
  50. height:480,
  51. backgroundColor:'#FFFFFF',
  52. top:240
  53. });
  54.  
  55. var catContainer = Titanium.UI.createView({ //container for buttons
  56. width:768,
  57. height:60,
  58. backgroundColor:'#6a7272',
  59. bottom:280
  60. });
  61.  
  62. var category = Titanium.UI.createButton({ //Category popover button 3
  63. backgroundImage:'images/categorybtn.png',
  64. width:167,
  65. height:41,
  66. left:290,
  67. opacity:1
  68. });
  69.  
  70. var nameContainer = Titanium.UI.createView({ //placeholder for category
  71. width:768,
  72. height:20,
  73. backgroundColor:'#f1df46',
  74. bottom:260
  75. });
  76. var app = Ti.UI.createWindow({
  77. width:768,
  78. height:1024
  79. });
  80. app.add(headerView);
  81.  
  82. app.add(roundedBorder);
  83. app.add(viewContainer);
  84. viewContainer.add(budget);
  85. viewContainer.add(room);
  86. catContainer.add(category);
  87. app.add(viewBdr);
  88. app.add(picContainer);
  89. app.add(catContainer);
  90. app.add(nameContainer);
  91. app.open({
  92. transition:Titanium.UI.iPhone.AnimationStyle.FLIP_FROM_LEFT
  93. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement