1. Hide the status bar [[uiapplication sharedapplication] setstatusbarhidden: Yes animated: No];
2. Open the mobile album
First, introduce the uiimagepickercontrollerdelegate protocol.
Uiimagepickercontroller * imgpickercontroller = [[uiimagepickercontrolleralloc] init];
Imgpickercontroller. Delegate = self;
Imgpickercontroller. sourcetype = uiimagepickercontrollersourcetypephotolibrary;
[Selfpresentviewcontroller: Self. imgpickercontrolleranimated: yescompletion: Nil];
3. Identify and display the running device type
Nsstring * devicetype = [uidevicecurrentdevice]. model;
Nslog (@ "current device type: % @", devicetype );
4. Number on the tabbar Image
Self. tabbaritem. badgevalue = [nsstringstringwithformat: @ "% d", 9];
5. Remove the lines between cells from tableview.
Mytableview. separatorstyle = uitableviewcellseparatorstylenone;
6. Load local file PDF
Nsurl * url = [[nsbundle mainbundle] urlforresource: @ "sample" withextension: @ "pdf"];
7.
Uitapgesturerecognizer * singletap = [[uitapgesturerecognizeralloc] initwithtarget: selfaction: @ selector (btnimageview :)];
[Self. imageviewaddgesturerecognizer: singletap];
-(Void) btnimageview :( ID) sender {
Cabasicanimation * Shake = [cabasicanimationanimationwithkeypath: @ "transform. Rotation. Z"];
// Set the jitter Amplitude
Shake. fromvalue = [nsnumbernumberwithfloat:-0.1];
Shake. tovalue = [nsnumbernumberwithfloat: + 0.1];
Shake. Duration = 0.1;
Shake. autoreverses = yes; // whether it is repeated
Shake. repeatcount = 4;
[Self. imageview. layeraddanimation: shakeforkey: @ "imageview"];
Self. imageview. Alpha = 1.0;
[Uiviewanimatewithduration: 2.0 delay: 2.0 options: uiviewanimationoptioncurveeaseinanimations: nilcompletion: Nil];
}
8.
// Set the background of uitableview to transparent
Table. backgroundview = nil;
Table. backgroundcolor = [uicolor clearcolor];
Table. opaque = no;
9.
To display a uiview at the beginning, you only need to call the bringsubviewtofront () method of its parent view.
To push a uiview layer to the backend, you only need to call the sendsubviewtoback () method of its parent view.