Guest User

Untitled

a guest
Mar 24th, 2018
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.85 KB | None | 0 0
  1. mthroutine name(ShowView)
  2. define_map for(*INPUT) class(#PRIM_ALPH) name(#pViewId)
  3.  
  4. define_com class(#PRIM_ALPH) name(#lPreviousViewId)
  5.  
  6. if (#mViews<#pViewId> *Is *NULL)
  7. #SYS_WEB.Alert( ("Missing &1").Substitute( #pViewId ) )
  8. return
  9. endif
  10.  
  11. #lPreviousViewId := #mCurrentViewId
  12. #mCurrentViewId := #pViewId
  13.  
  14. #mViews<#mCurrentViewId>.Activate
  15.  
  16. if ((#mViews<#lPreviousViewId> *IsNot *NULL) *And (#mViews<#lPreviousViewId> *IsNotEqualTo #mViews<#mCurrentViewId>))
  17. #mViews<#lPreviousViewId>.Deactivate
  18. #COM_OWNER.Transition from(#mViews<#lPreviousViewId>) to(#mViews<#mCurrentViewId>) transitiontype(Fade) duration(100)
  19. else
  20. * no previous view to transition from, so just make the current view visible
  21. #mViews<#mCurrentViewId>.Visible := True
  22. endif
  23.  
  24. #ViewContainerLayoutItem.Manage <= #mViews<#mCurrentViewId>
  25. #ViewContainerLayoutItem.Sizing := ContentHeightFitToWidth
  26. endroutine
Add Comment
Please, Sign In to add comment