Pushing Chat Controller with REMenu
bgottsch opened this issue · 5 comments
Hi Logan,
I decided to try out a Cocoa control in my app (https://github.com/romaonthego/REMenu) and when I try to push the ChatController it sometimes appears and sometimes not. I have tried with the storyboard config and programatically, but neither work. In the attempts It displayed, the ChatController's subviews where out of place. I think this might me the issue, since this controller creates a subview (I think) in the navbar area. Is there a way to change the frame of the subviews? If so what is the best way to do this? Also should I remove the ChatController's navbar subview?
Thanks in advance and congrats in the marvellous controller. It is simple, elegant and much better than other controllers out there.
Beno
Ps. an idea I had was to implement a slide to show time. I have found a way with table view but this uses a collection view (similar but not the same). I'm trying to implement this too and if I achieve it I'll let you know.
Hi Beno,
I will have time to actually go through the code tomorrow to take a look at this. I might create a new branch for navigation controllers since this has come up before.
You are right, I do add a subview in place of a Navigation Bar, it's called "TopBar". I can't remember the dependencies on it throughout the code, but if you remove it, I think it should still function.
Are you looking to present modally still, or are you trying to push via a navigation controller?
TimeSlide:
If you figure this out, definitely let me know! I already store a timestamp in the messages in anticipation that something like this would one day exist, hopefully that's helpful!
Best,
Logan
Logan,
I want to push it via a nag controller. Modally I was able to make it work. About the custom "TopBar", I was able to hide it but still the other superviews like the chat input are not in the right place. I think this REMenu controller changes the attributes SimpleChat uses as reference to position the superviews. When I try to present it, the ChatController takes control of my view and is there. The problem is with the positioning.
Thanks again for the support and controller,
Beno
Hi Beno,
I wanted to let you know that I was able to replicate your issue, and solved the layout part fairly easily by changing the flow layout edge insets.
However, now that things are laying out properly, I'm able to see another issue with scrolling. I am having a hard time tracking it down because it's so strange, but the scrolling does not work properly(consistently) unless there's at least around 15 messages (about 7 while keyboard is present).
I'm polling stack overflow currently here
I just wanted to keep you updated!
Best,
Logan
Hey Beno,
I was able to get everything working in a navigation controller. I don't have time to test every aspect, so let me know if you run into problems.
For now, a version with NavigationController support will exist on its own branch until I can be sure everything is rockin! You can find it here!
Make sure to set:
_chatController.isNavigationControllerVersion = YES;
Let me know if you need anything else to close this issue.
Best,
Logan
P.S. Let me know when you finish your app if you want it to be in an "Apps Using This Control" section.
Logan,
Sorry for replying late. It works perfectly. Thanks for the support. If all works out I'll certainly let you know of the app.
Beno