Class: PrimeSlidingMenu::SidebarContainerScreen
- Inherits:
-
ECSlidingViewController
- Object
- ECSlidingViewController
- PrimeSlidingMenu::SidebarContainerScreen
- Includes:
- MotionPrime::ScreenBaseMixin
- Defined in:
- lib/prime_sliding_menu/sidebar_container_screen.rb
Class Method Summary collapse
Instance Method Summary collapse
- #content_controller ⇒ Object
- #content_controller=(c) ⇒ Object
- #hide_sidebar ⇒ Object
- #menu_controller ⇒ Object
- #menu_controller=(c) ⇒ Object
- #show_sidebar ⇒ Object
- #toggle_sidebar ⇒ Object
Class Method Details
.new(menu, content, options = {}) ⇒ Object
5 6 7 8 9 10 11 12 |
# File 'lib/prime_sliding_menu/sidebar_container_screen.rb', line 5 def self.new(, content, = {}) screen = self.alloc.initWithTopViewController(nil) screen.on_create(.merge(navigation: false)) if screen.respond_to?(:on_create) screen. = unless .nil? screen.content_controller = content unless content.nil? screen.setAnchorRightRevealAmount 260.0 screen end |
Instance Method Details
#content_controller ⇒ Object
51 52 53 |
# File 'lib/prime_sliding_menu/sidebar_container_screen.rb', line 51 def content_controller self.topViewController end |
#content_controller=(c) ⇒ Object
35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/prime_sliding_menu/sidebar_container_screen.rb', line 35 def content_controller=(c) @content_controller_ref = prepare_controller(c) if should_reinit_content?(@content_controller_ref) self.topViewController = @content_controller_ref @content_controller_ref.view.addGestureRecognizer self.panGesture @content_controller_ref.view.addGestureRecognizer self.resetTapGesture else content_controller.viewControllers = [@content_controller_ref] end end |
#hide_sidebar ⇒ Object
18 19 20 |
# File 'lib/prime_sliding_menu/sidebar_container_screen.rb', line 18 def self.resetTopViewAnimated(false) end |
#menu_controller ⇒ Object
47 48 49 |
# File 'lib/prime_sliding_menu/sidebar_container_screen.rb', line 47 def self.underLeftViewController end |
#menu_controller=(c) ⇒ Object
30 31 32 33 |
# File 'lib/prime_sliding_menu/sidebar_container_screen.rb', line 30 def (c) = prepare_controller(c) self.underLeftViewController = end |
#show_sidebar ⇒ Object
14 15 16 |
# File 'lib/prime_sliding_menu/sidebar_container_screen.rb', line 14 def self.anchorTopViewToRightAnimated(false) end |
#toggle_sidebar ⇒ Object
22 23 24 25 26 27 28 |
# File 'lib/prime_sliding_menu/sidebar_container_screen.rb', line 22 def if self.currentTopViewPosition == 2 else end end |