V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
iOS 开发实用技术导航
NSHipster 中文版
http://nshipster.cn/
cocos2d 开源 2D 游戏引擎
http://www.cocos2d-iphone.org/
CocoaPods
http://cocoapods.org/
Google Analytics for Mobile 统计解决方案
http://code.google.com/mobile/analytics/
WWDC
https://developer.apple.com/wwdc/
Design Guides and Resources
https://developer.apple.com/design/
Transcripts of WWDC sessions
http://asciiwwdc.com
Cocoa with Love
http://cocoawithlove.com/
Cocoa Dev Central
http://cocoadevcentral.com/
NSHipster
http://nshipster.com/
Style Guides
Google Objective-C Style Guide
NYTimes Objective-C Style Guide
Useful Tools and Services
Charles Web Debugging Proxy
Smore
xiaoyu9965
V2EX  ›  iDev

求助一个诡异的问题!!!

  •  
  •   xiaoyu9965 · Oct 15, 2015 · 3042 views
    This topic created in 3853 days ago, the information mentioned may be changed or developed.

    在 AFSoundManager 中,无法在播放队列中修改 UI,不然会修改掉,界面上 UI 的 anchorPoint 。
    例如代码:
    playQueue = AFSoundQueue.init(items: [item1,item2,item3,item4,item5,item6])
    playQueue.pause()
    playQueue.listenFeedbackUpdatesWithBlock({aFSoundItem in

    self.palyProgress.setProgress(Float(aFSoundItem.timePlayed)/Float(aFSoundItem.duration), animated: true)
            let playText = String(aFSoundItem.timePlayed)+"/"+String(aFSoundItem.duration)
            self.playTime.text = playText
    
            }, andFinishedBlock: { nextAFSoundItem in
    
                //print(nextAFSoundItem.title)
    
        })
    

    就会很诡异的修改了界面上 UI 的 anchorPoint 。

    4 replies    2015-10-16 13:14:35 +08:00
    sparanoid
        1
    sparanoid  
       Oct 15, 2015
    请勿多节点重复发贴,其他的主题已删除
    xiaoyu9965
        2
    xiaoyu9965  
    OP
       Oct 15, 2015
    @sparanoid 不是有意的,理解下解 BUG 的心情~~~~
    jesse_luo
        3
    jesse_luo  
       Oct 16, 2015
    dispatch 到 main_queue 试试?
    xiaoyu9965
        4
    xiaoyu9965  
    OP
       Oct 16, 2015
    @jesse_luo 也试过在主线程中去更新 UI ,但是问题依然没有解决.......=。=
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   969 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 39ms · UTC 23:40 · PVG 07:40 · LAX 16:40 · JFK 19:40
    ♥ Do have faith in what you're doing.