How to jump from an event handler in story board to the code - iphone

I have a "Hello" button in the main view. I have set its Touch Up Inside handler to changeGreeting() in HelloWorldViewController.m. From the Connections Inspector, I can clear see this association:
My question is, how to jump to changeGreeting() function in the .m file from here (the story board view)?
I would expect simply clicking on that "Hello World View Controller changeGreeting:" button would bring me to the source code. But it turns out not the case.

There is no way (as far as I can tell) to jump directly from that panel to the changeGreeting: method.
You can press Command-Shift-O (or choose File > Open Quickly…) and type changeGreeting: (or some prefix of it) to jump to the definition.
If you want Apple to add a better way, go to https://bugreport.apple.com/ and file a feature request.

You could go to the 'Jump Bar' which is the horizontal bar at the top of the main viewer. Here change the file to the .m file and then start typing 'change' or 'greeting' to see all the methods in this file that match the filter.

Related

Swift ViewController does not respond to -getFile, Could not connect action, target class

My code works all fine but there is always two console message every time I run it.
app works fine but the messages just bugs me so much. Could anyone tell me what is wrong with my code and what does these console message means,thanks
2016-06-13 14:31:15.014
LazyHackintoshGenerator[1625:37250] Could not connect action, target class
LazyHackintoshGenerator.ViewController does not respond to -getFile:
Select your ViewController.
Right-click on its “View Controller” icon (the blue circle with a white square inside).
Look for warning icons (yellow triangles).
Hover over them. An explanation of the problem will appear.
As Feldur said, the problem is probably a leftover link from your storyboard to a method that does not exist anymore (maybe you renamed it or deleted it manually). Remove the link by clicking on the cross, and, if needed, re-link to the appropriate method in your code.
Here is an example of what it will look like in Interface Builder.
Likely a control's action in your storyboard is linked to a method getfile that no longer exists

How to implement a button into Simulink Subsystem Mask?

As I need to specify a local variable to a Subsystem, I created a mask. Doing that I lose the easy access to the subsystem. Right-click and navigating to "Look under mask" is supposed to be too complicated.
So I thought about a workaround and built the following:
The dialog callback code behind the "Get deeper!" checkbox is:
myParameter = %Parameter set by checking Get deeper!
path = gcb(gcs);
if strcmp(get_param(gcb,'myParameter'),'on')
open_system(path,'tab');
end
Everytime when I check the box, the subsystem gets opened and also by every double click on the subsystem, in case the box was checked before. Hence the code does what it should, but thats actualy not the common way how one would realize/visualize something like this.
What I want is a button "Look under mask" in my mask - so the subsystem just gets opened by clicking on that button. Basically the button should call the function: open_system(gcb(gcs),'tab'). Looks so easy, but Simulink doesn't offer me any option to implement this. Can anybody help?
The main issue whith the current solution is also that with every execution of the model all subsystems open up, where the box is checked. That's not the idea.
Matlab 2012b adds exactly what you want: masked blocks have a button on the botton left that is a shortcut to "Look under mask".
Unfortunately, I don't think it is possible to add a button in a mask.
You may want to change your function to automatically set the "Get deeper!" checkbox off after the user clicks on it. That would avoid the automatic opening of the subsystems when the model is loaded. You could do that adding set_param(path,'myParameter','off') just after the open_system(path,'tab');
Finally, as another workaround, you may want to set the OpenFcn callback to call open_system(gcb,'tab'). This will make the system work as if it isn't masked at all. You can put two open_system calls, one to look under mask and the other to open the mask dialog box, if you prefer.

Is there a simple source code viewer plugin for eclipse?

for example
setMediamixDefaultTime(mediamixVO);
boolean booked = false;
Long campaignSeq = mediamixVO.getCampaignSeq();
when I want to know about how to declared setMediamixDefaultTime() method,
I have to jump to setMediamixDefaultTime() declaration line.
It's very annoying especiouly source code is long..
so I need that is,
if I move mouse to that method or keyboard shortcut, the method declaration popup in small window.
just crtl+click on the item you want to jump to.
There is also an outline view, which shows the program structure.
Control + mouse click on the method will take you to the method declartion and you can use the back button to come back to the previous code.
Again the shortcut for back button is Alt + left arrow
You can make use of the Declaration View if you don't want to lose your place, but the Navigate menu's "Last Edit Location", Back, and Forward actions may also work.

strange methods showing in First Responder received actions

I am curious about something that I am seeing in interface builder when I right click on the "First Responder" placemark. My question is when I right click the "First Responder" lists its received actions, amongst theses are 5 methods that are defined in one of my early classes, does anyone know why they are showing up, does it matter, is this normal?
EDIT:
If I right click on [First Responder] on any of the nib/xib files in my project (there are 4) I see the following.
I am just curious why the buttonPressed_XXX methods display in that list (for all the xibs in the project).
http://i.stack.imgur.com/WBMsk.png
First reponder is action of Keyboard to go off after you finish typing.. in above image all these actions uses keyboard so it shows that page when you remove the action(IBAction) thats it...
Did you delete the references from IB? XCode doesn't automatically delete the IBOutlets or IBActions if you hook up objects and get rid of the objects or IBActions. Press x beside the name of the object and the object type to get rid of the IBAction or Outlet. A picture could be helpful.

Xcode Meanings. "window"

Hello StackOverflow people :)
I have a simple question regarding Xcode (cocoa) "Apple application maker"
Q : What is the name for the transition between 2 windows?
and do I make another "file" in the resources to make another window?
Thanks!
any extra details is appreciated
The transitions are just animations most of the time, but we can add in extra effects like fading and flipping depending on the type of the new window/view that we want to load. Within Xcode, the terminology to view and see a new window is called a "push" - as you push it onto the view hierarchy. To close it, you "pop" it off the stack.
And yes, you simply make a new file and then choose it's type to make another window - depends on exactly which type you are after, whether it's a code file or interface file etc.
Hope this helps.