Apple MAC Archives

We can get the child view controllers of a view controller using the childViewControllers property of the view controller.

If we are in a view controller class, if we want to get its child view controllers, then we can use the following code :

self.childViewControllers;

This will return an array of view controllers that are the child of the current view controller.

If there are no child view controllers of the current view controller, then the array will be empty.

 

If we are to get the child view controllers of a navigation controller, we can use the following code :

self.navigationController.childViewControllers;

Incoming search terms:

  • current childview controller
  • access child view in titanium
  • AppleMAC|Web eCommerce iOS Android ArduinoandSEO
  • how to find a view\s viewcontroller in childviewcontrollers array
  • xcode child view controller
  • xcode get child of navigation controller
  • xcode parent and child view

It is possible to pass a single parameter to performSelector: method in Xcode using the following method :

 

[self performSelector:@selector(selectorNamewithArg:) withObject:param];

 

But what to do if we have to pass multiple parameters? There is a way to pass upto two parameters to the performSelector: method. It can be implemented using the following method :

 

[self performSelector:@selector(selectorNamewithArg1: Arg2:) withObject:param1 withObject:param2];

 

Here, two parameters are passed to the selector method.

 

Incoming search terms:

  • xcode multiple arguments

How to Boot to a Different OS in Dual-boot Mac

You can use Bootcamp to install install windows OS on a mac machine. Once your system is ready with windows OS and a mac OS, you can switch between the OS using the following methods :

 

- For the first and the simplest method, restart the Mac and while restarting, press the Alt button on the keyboard. This will bring the option to choose the OS you want to use.

- Another method you can use is using the system preferences. Choose startup disk from the system preferences items. In the window which appears, you will be able to see the partitions and OS installed in the mac. From there choose the partition you want to boot to and click the “Restart…” button. Now your mac will restart with the OS you have selected.

 

These are the two simple and easy steps to switch OS in dual boot mac.

Re-Indexing Volumes or Folders in Mac

For re-indexing volumes or folders in a mac, follow the steps given below :

- Goto the Apple menu and select the System Preferences option.

- From the set of spotlight items, click Spotlight to open spot preferences.

- Click the Privacy tab in the resultant window.

- Drag an entire volume or folder to the list or add using the “+” button at the bottom.

- If prompted or confirmation, press the ‘ok’ button and proceed.

- Now remove the item we have just added to the list by selecting the item and pressing the “-” button at the bottom.

- Close spot light preferences.

Now if you open spotlight, you will be able to see that its started re-indexing the files in your mac.

Keyboard Shortcut to Open Task Manager in Mac

It is possible to open task manager in mac using keyboard shortcut. The keyboard shortcut used for this is :

Alt + Cmd + Esc

Incoming search terms:

  • how make shortcut of android manager on mac

Keyboard Shortcut to Logout User in Mac

It is possible to logout the current logged used in mac using keyboard shortcut. The keyboard shortcut used for this is :

Shift + Cmd + Q

Incoming search terms:

  • logoff shortcut ios

Each push notification payload will contain the following keys in dictionary format : alert, badge and sound.

key : alert

Value Type : string or dictionary

Comment : If this property is included, iOS displays a standard alert. We may specify a string or a dictionary as the value of alert. If we specify a string, it becomes the message text of an alert with two buttons: Close and View. If the user taps View, the application is launched. If the user taps close, the notification will disappear.

 

key : badge

Value Type : number

Comment : This number will be used to display as the badge of the application icon. If this property is absent, the badge is not changed. To remove the badge, set the value of this property to 0. We can also give the value for this property as string. BUt we have to make sure that there is an integer value for the string we give.

 

key : sound

Value Type : string

Comment : This represents the name of a sound file in the application bundle of the application. The sound in this file is played as an alert. If the sound file doesn’t exist or default is specified as the value, the default alert sound is played.

 

Each Apple push notification carries with it a payload. The payload specifies how users are to be alerted to the data waiting to be downloaded to the client application. The maximum size allowed for a notification payload is 256 bytes.

For each notification, providers must compose a JSON dictionary object. This dictionary must contain another dictionary identified by the key Apple Push Notification Service. The Apple Push Notification Service dictionary contains one or more properties that specify the following actions:

  • An alert message to display to the user
  • A number to badge the application icon with
  • A sound to play

We can convert a CLLocation object to a CLLocationCoordinate2D object using the coordinate property of the CLLocation object. This can be done as follows :

 

Consider a CLLocation object name myLocation. Now we can get the equivalent CLLocationCoordinate2D of myLocation as,

 

CLLocationCoordinate2D myCoordinate = myLocation.coordinate;

 

We can obtain the latitude and longitude of a CLLocationCoordinate2D object using its latitude and longitude properties.

 

i.e.,

double myLatitude = myCoordinate.latitude; // this will give the latitude value of the coordinate

double myLongitude = myCoordinate.longitude;// this will give the longitude value of the coordinate

Incoming search terms:

  • CLLocationCoordinate2D to cllocation
  • cllocation CLLocationCoordinate2D
  • cllocation to cllocationcoordinate2d
  • convert cllocation to cllocationcoordinate2d
  • ios CLLocationCoordinate2D与CLLocation
  • xcode cllocationcoordinate2d latitude
  • xcode cllocation from coordinates
  • ios develop CLLocation CLLocationCoordinate2D
  • how to convert cllocationcoordinate2d to cllocation
  • how to convert cllocation to double in ios

It is possible to initialize a CLLocation object with a latitude and longitude in Xcode. Consider two float values corresponding to the latitude and longitude value you want to use, as follows :

 

double your_latitiude_value = 8.391916;

double your_longitude_value = 77.094315;

 

We can initialize a CLLocation object using these latitude and longitude values as follows :

 

CLLocation *myLocation = [[CLLocation alloc] initWithLatitude:your_latitiude_value longitude:your_longitude_value];

Incoming search terms:

  • xcode howto enable cllocation
  • cllocationmanager iphone xcode
  • get latitude longitude cllocationcoordinate2d
  • how to create cllocation object
  • ios CoreLocation make CLLocation from latitude longitude
  • xcode cllocation with latitude longitude
  • xcode howto cllocation google by address
  • xcode latitude longitude from address google
Page 1 of 712345...Last »