Bounce Layer-Success page
jt-secondary Swimming-east to shun-three sanlitun-hug-Adidas-hand-bus stop hug-elevator first floor pro-home
Translucent View Add white alertview stacked label, constrained write, model transfer copy, according to the copy of the height of the full stack, so that the White View center with a translucent matte background is the same
-------
/**
* Find string Lengths
*
* @param text string
*
* @return String width
*/
-(float) Width: (NSString *) text{
Cgsize size = [text Sizewithfont:[uifont systemfontofsize:kcelltextfont]constrainedtosize:cgsizemake (MAXFLOAT,27) ];
Cgsize size = [text Sizeautofitios7withfont:[uifont Systemfontofsize:kcelltextfont] Constrainedtosize:cgsizemake ( maxfloat,27) linebreakmode:nslinebreakbycharwrapping];
LOG (@ "Text---%@--size.width--%f", text,size.width);
return size.width;
}
-----------
Hdfnet *net = [Hdfnet shareinstance];
[NET Postaddpath:doctoruser_bookingorder_modifytingzhen
Parameters:parameters
success:^ (Hdfnetresponse *response) {
[Svprogresshud dismiss];
if (_isfromfacediaorderlist) {
Uialertview *alertview = [[Uialertview alloc] initwithtitle:@ "published successfully" message:@ "if a patient has been booked during the discontinuation, the doctor will contact the patient to cancel or change the time" delegate: Self Cancelbuttontitle:nil otherbuttontitles:@ "I Know", nil];
Alertview.tag = Kfacediaorderalerttag;
[Alertview show];
}
else{
[Svprogresshud showsuccesswithstatus:@ "published successfully"];
[Self performselector: @selector (Poptoannoucelistviewcontroller) Withobject:nil afterdelay:0.5];
}
Performselector Pop controller delay of 0.5s after successful release
------------------------------------------------------------------------------------------------
First write about the constraints, do not write height constraints, and finally add height constraints
Blue Dashed Box ImageView
Uiimageview *dottedlineimageview = [[Uiimageview alloc]init];
[Self.bottomcontainerview Addsubview:dottedlineimageview];
[Dottedlineimageview mas_makeconstraints:^ (Masconstraintmaker *make) {
Make.top.equalTo (Self.bottomcontainerview);
Make.left.equalTo (Self.bottomcontainerview). Offset (25);
Make.right.equalTo (Self.bottomcontainerview). Offset (-25);
}];
Dottedlineimageview.image = [UIImage imagenamed:@ "Traveldoc_round"];
[Dottedlineimageview mas_updateconstraints:^ (Masconstraintmaker *make) {
Make.bottom.equalTo (Rightbutton.mas_bottom). Offset (15);
}];
-----
ScrollView cannot scroll
Self.bottomcontainerview = [[UIView alloc]init];
[Self.bgscrollview AddSubview:self.bottomContainerView];
[Self.bottomcontainerview mas_makeconstraints:^ (Masconstraintmaker *make) {
Make.top.equalTo (Self.offWorkReleaseLabel.mas_bottom). Offset (35);
Make.left.right.equalTo (Self.view);
Make.bottom.equalTo (Self.bgscrollview); Finally, we add the constraint.
}];
All controls should be added to ScrollView. Before the second line was written
[Self.view AddSubview:self.bottomContainerView];
-----
Standard notation for scrolling views
1. Set four-sided constraint all view add to ScrollView without setting contentsize, do not set proxy
Uiscrollview *bgscrollview = [[Uiscrollview alloc]init];
[Self.view Addsubview:bgscrollview];
[Bgscrollview mas_makeconstraints:^ (Masconstraintmaker *make) {
Make.edges.mas_equalTo (Self.view);
}];
(How to set top.left,right only, is not possible, updating the constraint means that the constraint has been previously)
2. Update the bottom edge constraint
[Bgscrollview mas_updateconstraints:^ (Masconstraintmaker *make) {
Make.bottom.mas_equalTo (Self.bottomContainerView.mas_bottom). Offset (15);
}];
-----
Font.lineheight * 0.4
--------------------------------------------------------
@property (nonatomic, strong) ID model;
-(void) Setmodel: (ID) model
{
if ([Model Iskindofclass:[ptofflineannouncemodel class]]) {
_offlineannouncemodel = model;
}
else if ([Model Iskindofclass:[ptonlineannouncemodel class]])
{
_onlineanouncemodel = model;
}
[Self configureui];
}
One controller may pass two models
--------------------------------------------------------------------------------
Add UI first and refresh UI with model
--------------------------------------------------------------------------------
button click Cannot jump
Because the button's parent control is a picture, the picture is not interactive by default, so it's OK to set up the picture interactively.
----------------------------------------------------------------------------------------------------
Crash Info: __nsarrayi removeobject
Google Baidu search crash information can find the answer, the problem in the first code, cast, but VCs is still immutable group, to deceive the compiler, the actual or non-variable group, so
Nsmutablearray * vcs = [Nsmutablearray arrayWithArray:self.navigationController.viewControllers];
Writing with Arraywitharray won't crash.
Different memory space equivalent to ALLOC init
Right Slide back
-(void) removeofflineannounceeditviewcontroller{
Nsmutablearray * vcs = (Nsmutablearray *) self.navigationController.viewControllers;
For (Uiviewcontroller * VC in Self.navigationController.viewControllers) {
if ([VC Iskindofclass:[offlineannounceeditviewcontroller Class]]) {
[VCs REMOVEOBJECT:VC];
[Self.navigationcontroller Setviewcontrollers:vcs Animated:no];
Self.navigationController.viewControllers = vcs;
}
}
}
------------------------------------------------------------------------------------------
/**
* Stretch picture, edges not deformed
*
* @param image stretched image
*
* @return Stretched picture
*/
-(UIImage *) Strenthimage: (UIImage *) Image {
CGFloat top = 31; Top cover Height
CGFloat bottom = 31; Bottom cover Height
CGFloat left = 10; Left cover width
CGFloat right = 10; Right End cover width
Uiedgeinsets insets = Uiedgeinsetsmake (top, left, bottom, right);
Specified as stretch mode, re-assigned after scaling
return [Image Resizableimagewithcapinsets:insets Resizingmode:uiimageresizingmodestretch];
}
------------------------------
Last update constraint not
No, you can use make to constrain it.
--------
No notes displayed
Solve with ScrollView + label
------
5.9-Stop the scene to introduce a business trip