在Apple最近发布的Remote应用程序中,我注意到导航栏的行为方式是独特的,我无法重现它.当弹出正在播放视图控制器时,导航栏对于正在播放视图控制器保持透明,并且库视图控制器的导航栏也保持半透明(屏幕截图1).我想弄清楚他们是使用两个导航控制器还是只使用一个.我个人觉得他们只使用一个有两个原因(1)启用了交互式弹出手势; (2)当您按下库视图控制器中的"正在播放"按钮时,就在现在播放屏幕完成"推视控制器"动画之前,导航栏变为透明(屏幕截图2).这是我按下视图控制器时所遇到的行为(将导航栏设置为透明).所以我的问题是:Apple如何呈现两个视图控制器的两个视图控制器的导航栏,就像它们是个体一样(如屏幕截图1),甚至条形按钮,导航标题等...切换时的不透明度为100%(通常在当按下新控制器时,按下/弹出前一个视图控制器的按钮和标题会逐渐消失.我试着玩弄了吧色调颜色viewDidAppear,并viewWillAppear在这两个视图控制器,但无法重现相同的行为,并不能防止褪色栏按钮.
天哪我希望我已经很好地解释了这一点,我只是想着它而感到困惑!
截图1(弹出):

截图2(推送):

我确定我在这里忽略了一些东西,但无法解决这个问题.我的第二个内联块div上面有空白区域,这只有在右侧div中的"text here"长度小于左侧时才会出现.
jsFiddle:http://jsfiddle.net/B2S4r/2/(你需要让HTML视图更宽,以便彼此一起看到它们)
<div style="border-top: 1px dashed black; display: inline-block; width: 250px; margin-bottom: 10px; margin-right: 10px; margin-top: 0;">
<div style="height: 50px; padding-top: 2px; padding-bottom: 2px; text-align:right; font-size: 11px;">
<div style="display: block; width: 80px; height: 50px; float: left; background-color: #cdcdcd; background-position: left center;">
</div>
<span class="main_header" style="font-size: 21px; margin: 0;">Title</span>
<br />
Subtitle
</div>
<div style="display:block; background-color: #efefef; height: 75px; padding: 5px; font-size: 12px;">
Text here Text here Text here Text here Text here Text here Text …Run Code Online (Sandbox Code Playgroud) 我已经分类了UITableViewCell,在那个课程中我应用了一个Pan手势识别器:
UIPanGestureRecognizer *panning = [[UIPanGestureRecognizer alloc]initWithTarget:self action:@selector(handlePanning:)];
panning.minimumNumberOfTouches = 1;
panning.maximumNumberOfTouches = 1;
[self.contentView addGestureRecognizer:panning];
[panning release];
Run Code Online (Sandbox Code Playgroud)
然后,我实现了委托协议,该协议应该允许在表的视图中同时进行手势:
- (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer {
return YES;
}
Run Code Online (Sandbox Code Playgroud)
然后我在handlePanning方法中放置一个日志,看看它何时被检测到:
- (void)handlePanning:(UIPanGestureRecognizer *)sender {
NSLog(@"PAN");
}
Run Code Online (Sandbox Code Playgroud)
我的问题是我无法垂直滚动查看tableview中的单元格列表,handlePanning无论我在哪个方向上调用它都会被调用.
我想要的handlePanning只是在只有水平平移而不是垂直时调用.会很感激一些指导.
我在SO上的另一个帖子中读到,您可以在添加CALayer的UITableView中调整索引栏(即AZ#滚动条)的字体或背景颜色.我的应用程序将在iOS 5及更高版本上运行,因为我在Apple文档中没有看到任何相关内容,如果没有创建自定义表格视图,这是不可能的?
如果这是可能的(并且Apple可以接受),我将如何做到这一点?
我已经阅读了很多关于SO的帖子,并且所提出的解决方案都没有为我工作.我希望那些对解释错误有更多了解的人可以提供帮助.
我的应用程序一直运行良好(现在仍然如此),但是当使用某个类'iCarousel'时,我遇到了一个问题,这是一个Cover Flow的实现.
这是有趣的事情:当打开iCarousel的示例项目时,它在我的iPhone上正常运行.我的应用程序(在一个单独的项目中)也运行良好.他们都使用armv6 armv7 架构并在iOS 5.1上运行.
然后我将类复制到我自己的项目并添加所有必要的框架.还没有错误.但是当我构建并运行时,我收到一个错误:
Ld /Users/Sooper/Library/Developer/Xcode/DerivedData/TestApp-
ejfsezvwxyxhqpanwwrcmsbkslxi/Build/Intermediates/TestApp.build/Debug-
iphoneos/TestApp.build/Objects-normal/armv7/TestApp normal armv7
cd "/Users/Sooper/Developer/TestApp v1.0"
setenv IPHONEOS_DEPLOYMENT_TARGET 5.0
setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:
/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch armv7 -isysroot
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk
-L/Users/Sooper/Library/Developer/Xcode/DerivedData/TestApp-ejfsezvwxyxhqpanwwrcmsbkslxi/Build/Products/
Debug-iphoneos -F/Users/Sooper/Library/Developer/Xcode/DerivedData/TestApp-ejfsezvwxyxhqpanwwrcmsbkslxi/Build/Products/
Debug-iphoneos -filelist /Users/Sooper/Library/Developer/Xcode/DerivedData/TestApp-ejfsezvwxyxhqpanwwrcmsbkslxi/Build/Intermediates/TestApp.build/
Debug-iphoneos/TestApp.build/Objects-normal/armv7/TestApp.LinkFileList -dead_strip -miphoneos-
version-min=5.0 -lz -framework QuartzCore -framework CoreGraphics -framework
SystemConfiguration -lxml2.2.7.3 -framework Security -framework CoreMedia -framework Accounts
-framework CoreFoundation -framework AudioToolbox -framework AVFoundation -framework Twitter -
framework MediaPlayer -framework UIKit -framework Foundation -o
/Users/Sooper/Library/Developer/Xcode/DerivedData/TestApp-
ejfsezvwxyxhqpanwwrcmsbkslxi/Build/Intermediates/TestApp.build/Debug-
iphoneos/TestApp.build/Objects-normal/armv7/TestApp
Run Code Online (Sandbox Code Playgroud)
在此之下:
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_ArtworkScrollerViewController", …Run Code Online (Sandbox Code Playgroud) 我一直在玩AVPlayer它的子类AVQueuePlayer(以及一个MPMediaItems 数组)并发现后者在无间隙专辑中表现更好,但似乎都没有完全完成任务.
使用时,有当前和下一磁道之间的一个非常明显的暂停AVPlayer的replaceCurrentItemWithPlayerItem方法.但随着AVQueuePlayer的advanceToNextItem方法的间隙狭窄得多.
唯一的选择是这两个类,因为我正在处理AVPlayerItem包含iTunes音乐库中项目的资产URL的.这就引出了一个问题,是否可以通过iOS SDK实现无间隙播放?
基本上我想要的是应用程序,一旦用户允许访问他们的Twitter帐户,就能够发布用户在a中选择的任何内容UITableView.理想情况下,我想在iOS 5中使用Twitter框架,但我遇到的主要问题是用于推文的模态视图控制器.这是可选的吗?是否可以在没有它的情况下发推文,如果没有,你建议我做什么?
谢谢!
没有reCAPTCHA,我的页面看起来像这样(jsfiddle):
<html>
<body>
<div class="content_wrap">
<div class="left_container">
</div>
<div class="right_container">
<div style="background-color: blue; margin:0px; height: 1500px;">
<!--RECAPTCHA WOULD GO HERE-->
</div>
</div>
</div>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)
CSS:
body,html {
height: 100%;
width: 100%;
background-color: #f8f8f8;
}
div.content_wrap {
width: 100%;
position: relative;
}
div.left_container {
float:left;
position:absolute;
width: 220px;
min-height: 100%;
background-color: red;
}
div.right_container {
position: relative;
padding: 0px;
margin-left: 220px;
width: 1000px;
}
Run Code Online (Sandbox Code Playgroud)
使用reCAPTCHA(在蓝色区域中)整个页面内容的高度在底部减少~20px,并带有可见的白色空间条带.
有没有人有reCAPTCHA改变其布局元素的问题?
我正在尝试调整我在IB上为4英寸设备创建的MKMapView的框架,但它不起作用.这是我在viewDidLoad上的代码:
- (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view from its nib.
// Resizing UILabel for 4-inch screen
CGRect screenBounds = [[UIScreen mainScreen] bounds];
if (screenBounds.size.height == 568) // 4 inch
{
mapView.frame = CGRectMake(0, 44, 320, 504);
}
else // 3.5 inch
{
mapView.frame = CGRectMake(0, 44, 320, 416);
}
// END - Resizing UILabel for 4-inch screen
}
Run Code Online (Sandbox Code Playgroud)
谁能告诉我这个设置有什么问题?谢谢.
代码使用部分工作和填充表,但它有一个缺陷:它不会逃脱标点符号和歌曲标题中的''前缀,就像本机音乐应用程序的做法一样.
非常感谢我应该如何做到这一点.
- (void)viewDidLoad
{
[super viewDidLoad];
MPMediaQuery *songQuery = [MPMediaQuery songsQuery];
self.songsArray = [songQuery items];
self.sectionedSongsArray = [self partitionObjects:self.songsArray collationStringSelector:@selector(title)];
}
- (NSArray *)partitionObjects:(NSArray *)array collationStringSelector:(SEL)selector
{
UILocalizedIndexedCollation *collation = [UILocalizedIndexedCollation currentCollation];
NSInteger sectionCount = [[collation sectionTitles] count];
NSMutableArray *unsortedSections = [NSMutableArray arrayWithCapacity:sectionCount];
for(int i = 0; i < sectionCount; i++)
{
[unsortedSections addObject:[NSMutableArray array]];
}
for (id object in array)
{
NSInteger index = [collation sectionForObject:object collationStringSelector:selector];
[[unsortedSections objectAtIndex:index] addObject:object];
}
NSMutableArray *sections = [NSMutableArray arrayWithCapacity:sectionCount];
for (NSMutableArray …Run Code Online (Sandbox Code Playgroud) ios ×7
cocoa-touch ×4
css ×2
html ×2
objective-c ×2
uitableview ×2
avplayer ×1
ios6 ×1
mkmapview ×1
mpmediaquery ×1
recaptcha ×1
twitter ×1