Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

zoran

macrumors 601
Original poster
Jun 30, 2005
4,782
129
Is it possible to see programming code of the Calendar and Clock apps of iOS?
 

zoran

macrumors 601
Original poster
Jun 30, 2005
4,782
129
Its amazing that those two apps have code that provide a preview of their function on the app icons! Thats the code im looking for.
 

Mascots

macrumors 68000
Sep 5, 2009
1,667
1,418
Its amazing that those two apps have code that provide a preview of their function on the app icons! Thats the code im looking for.

No, their code is not available and there's no way to mirror what is done to the app icons: it is done on the OS level in Springboard.

The most you can do is replace the app icon within your app but that requires your app to be open and the user to agree to a prompt.
 

zoran

macrumors 601
Original poster
Jun 30, 2005
4,782
129
Springboard?

The most you can do is replace the app icon within your app but that requires your app to be open and the user to agree to a prompt.
I got no clue what you mean here! :(
 

Mascots

macrumors 68000
Sep 5, 2009
1,667
1,418
Springboard is the application that creates and manages the home screen (among other things). Within there are a set of classes (SBClockApplicationIcon) which manage the icons views accordingly.
That is all behavior private to Apple and has nothing really to do with the application itself.

However, Apple has recently added a method called setAlternateIconName which lets you change your icon to something predefined, with users permission.
 
Last edited:

zoran

macrumors 601
Original poster
Jun 30, 2005
4,782
129
So, in case i want to make an app, say for eg. like a digital clock and have the icon displaying time just like "clock" cant it be done?
 

AxoNeuron

macrumors 65816
Apr 22, 2012
1,251
855
The Left Coast
While you can change the app's icon image, these images must be saved in advance in the project directory.

Also, when the icon changes, the system will show an alert to the user saying 'You have changed the icon for {app name}".

Because of that alert, it wouldn't be possible to replicate what the Clock app does, since it would have to be A) done while the app is launched and B) would have to show the user the popup alert every time the icon changes, which in the case of the clock app, would be every second.
 

zoran

macrumors 601
Original poster
Jun 30, 2005
4,782
129
Im not willing to replace the iOS's clock app, im only trying to test to see if i can make a different clock app with the same potentials as far as the icon i concerned.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.