Skip to content
This repository has been archived by the owner on Jun 8, 2023. It is now read-only.

RBLPopover setContentSize won't resize the Popover dynamically like in NSPopover #94

Open
ghost opened this issue Jul 5, 2013 · 3 comments

Comments

@ghost
Copy link

ghost commented Jul 5, 2013

RBLPopover should mimic the Behavior of NSPopover. If the Size of a ViewController's View changes, the Popover is allready shown and I perform

[popover setContentSize:NSMakeSize(controller.view.frame.size.width, controller.view.frame.size.height)];

the Popover should resize dynamically, like NSPopover does! RBLPopover however does not resize.

NSPopover contentSize Docu:
"The popover's content size is set to match the size of the content view when the content view controller is set. Changes to the content size of the popover will cause the popover to animate while it is shown if the animates property is YES. This property is exposed as a read-only binding."

@ghost
Copy link
Author

ghost commented Jul 5, 2013

Anyone familiar with the Rebel Code has an Idea for a concept on how to achieve this? I might give it a try but from the first look at the code I don't know where to start, the only Method that seems to do everything in RBLPopover is - showRelativeToRect:ofView:preferredEdge: ? But I believe calling this Method again will create the whole Popover again and not resize it animated.

@dannygreg
Copy link

Yep I would say that is definitely a valid feature request.

Anyone familiar with the Rebel Code has an Idea for a concept on how to achieve this?

When the popover get's told to change it's contentsSize it should simply change the size of it's popoverWindow. That will even take care of any animations.

@ghost
Copy link
Author

ghost commented Sep 17, 2013

Couldn't get it to work. My knowledge of NSView programming seems to limited. Can someone help? I need this badly but am totally stuck right now.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant