Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't get buttons to work #16

Closed
ghost opened this issue Nov 7, 2015 · 4 comments
Closed

Can't get buttons to work #16

ghost opened this issue Nov 7, 2015 · 4 comments

Comments

@ghost
Copy link

ghost commented Nov 7, 2015

What a fantastic sidebar menu!

I added the swift file in my project;
I added the script:
var frostedSidebar: FrostedSidebar = FrostedSidebar(images: imageArray, colors: colorArray, selectionStyle: chosenSelectionStyle)
And changed the right things;

I added the following script to a button function:
frostedSidebar.showInViewController( self, animated: true )

And al of this works perfect! The sidebar is showing and the animations works fine.

But i just can get the button action inside the sidebar to work. I don't have a tabbar in my project. I do have 3 viewcontrollers and added a navigation controller. I know how to use segues.

Can you tell me how to get respons from the sidebar buttons? I don't know how and where to use the given script: frostedSidebar.actionForIndex[idx] = { /* actions */ }

@ghost
Copy link
Author

ghost commented Nov 7, 2015

Ok, added the tabbar. Now it works fine! Tnx!

@ghost ghost closed this as completed Nov 7, 2015
@edekhayser
Copy link
Owner

Glad I could help 😜

@ghost
Copy link
Author

ghost commented Nov 9, 2015

Hi evan,

Any idea how to preform a tableView refresh if a user hits a button in the sidebar.

I know how to preform a refresh normally, but I get an error if I call the 'refresh' function in your code.
Errorline: TableView.reloadData()

I think it's the same problem but I would also like to refresh of reload the view if a user hits the button from the current view controller.

Kind regards,

Ronald Baks


From: Evan Dekhayser <notifications@github.commailto:notifications@github.com>
Sent: zaterdag, november 7, 2015 4:39 p.m.
Subject: Re: [FrostedSidebar] Can't get buttons to work (#16)
To: edekhayser/FrostedSidebar <frostedsidebar@noreply.github.commailto:frostedsidebar@noreply.github.com>
Cc: Brain2success <rebaks@live.nlmailto:rebaks@live.nl>

Glad I could help ?

Reply to this email directly or view it on GitHubhttps://github.com//issues/16#issuecomment-154716758.

@edekhayser
Copy link
Owner

It depends on the error. Try adding "self." so it says "self.tableView.reloadData()"

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant