菜鸟教程小白 发表于 2022-12-11 22:43:07

objective-c - UIApplication空闲定时器


                                            <p><p>这是一个简单的问题,我似乎找不到任何关于它的信息,但我只想知道下面的代码是否会让我的应用程序被拒绝。基本上,这是一个私有(private) API</p>

<pre><code>;
</code></pre>

<p>我想将此添加到我的 AppDelegate 中的 didFinishLaunchingWithOptions 下。我只是不想使用如此简单的东西并让我的应用程序被拒绝。感谢您提供任何信息!</p></p>
                                    <br><hr><h1><strong>Best Answer-推荐答案</ strong></h1><br>
                                            <p><p>这是公开的,尽管苹果建议:</p>

<blockquote>
<p>Important You should set this property only if necessary and should be
sure to reset it to NO when the need no longer exists. Most
applications should let the system turn off the screen when the idle
timer elapses. This includes audio applications. With appropriate use
of Audio Session Services, playback and recording proceed
uninterrupted when the screen turns off. The only applications that
should disable the idle timer are mapping applications, games, or
similar programs with sporadic user interaction.</p>
</blockquote>

<p>因此,如果您的应用与他们描述的一样,或者您谨慎使用它,那么您应该没问题。</p></p>
                                   
                                                <p style="font-size: 20px;">关于objective-c - UIApplication空闲定时器,我们在Stack Overflow上找到一个类似的问题:
                                                        <a href="https://stackoverflow.com/questions/10200522/" rel="noreferrer noopener nofollow" style="color: red;">
                                                                https://stackoverflow.com/questions/10200522/
                                                        </a>
                                                </p>
                                       
页: [1]
查看完整版本: objective-c - UIApplication空闲定时器