问题标签 [uiprogressview]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
iphone - 当 0.0 < progress < 0.03 时 UIProgressView 不会改变
我有一个 UIProgressView,我用它来直观地表示一分钟计时器。它的宽度为 280 像素。我正在使用 NSTimer 逐渐减小“进度”的值,从进度 = 1.0 开始。“进度”每十分之一秒更新一次。除了最后两秒钟,它完全按照我的意愿行事。
一旦“进度”的值低于 0.03,UIProgressView 的移动就会停止(显示大约 0.2 厘米的条形图),直到“进度”达到 0.0,此时 0.2 厘米的条形图就会消失。
有谁知道为什么 UIProgressView 会这样?这是设计使然,还是我做错了什么?
编辑:
月,
我不认为它与舍入有关,因为在 NSTimer 调用的方法中,我使用 NSLog 来显示“进度”的值,并且它打印有六个有效数字,例如
2009-12-31 21:13:22.462 XXXXXXX 0.101669
2009-12-31 21:13:22.562 XXXXXXX 0.100003
此外,如果是这样的话,所有的动作都会是波涛汹涌的,不仅仅是最后两秒钟。这是 NSTimer 调用的代码:
iphone - 是否可以将元素添加到导航控制器的底部工具栏?
我想在导航控制器底部的工具栏中添加进度视图和活动指示器视图。但是当我拖放它时,它会适用于整个窗口吗?
我该怎么做?
iphone - 如何在我的应用程序中显示 UIProgressView 以供下载?
我想显示一个进度条,指示在我的 iPhone 应用程序中下载了多少文件。我知道如何在 IB 中设置 UIProgressView 等等。但是我需要诸如文件大小(以字节为单位)之类的数据来运行它。如何将此类功能与我的字节下载代码(如下所示)集成?
iphone - 如何确定使用 NSURLConnection 下载文件的大小(以字节为单位)?
我需要知道使用 NSURLConnection (GET) 下载到我的应用程序中的文件的大小(以字节为单位)。如果有帮助,这是我收到的字节代码。我需要知道的是如何以字节为单位获取文件大小,以便我可以使用它来显示 UIProgressView。
iphone - UIProgressView 未更新
我有一个 UIProgressView 我正在尝试更改进度但从未更新。我的“慢”操作是从 NSoperation/NSOperation 队列完成的,所以它应该是多线程的。
您是否已经经历过这种情况,或者您有解决这个问题的想法吗?
谢谢 :)
iphone - iPhone:如何设置清晰的窗口大小的“阻止视图”?
我觉得这对我来说应该很明显,但由于某种原因我无法弄清楚。我有一个带有导航栏、工具栏和主视图的导航界面。有时,用户采取的操作会导致进度指示器出现在视图中间。
虽然进度指示器(这是一个自定义 UIView)在中间旋转,但我希望不允许触摸输入进入任何底层界面(主视图、导航栏、工具栏等)。但这似乎并不简单。
我已经尝试(但失败了)创建一个简单的视图,其唯一的工作就是吞下触摸输入并将其用作窗口子视图——没有骰子,它永远不会获得触摸事件(是的,它确实具有 userInteractionEnabled)。我试图将它作为一个透明的模态视图控制器,但那些似乎从来都不是透明的。
想法?我错过了什么?
谢谢!
iphone - Update iPhone UIProgressView during NSURLConnection download
I am using this code:
to download a file, and I want to update a progress bar on a subview that I load. For that, I use this code:
The subview is oDPVC, and the progress bar on it is oProgress. Setting the progress property does not update the control.
From what I have read on the Web, lots of people want to do this and yet there is not a complete, reliable sample. Also, there is much contradictory advice. Some people think that you don't need a separate thread. Some say you need a background thread for the progress update. Some say no, do other things in the background and update the progress on the main thread.
I've tried all the advice, and none of it works for me.
One more thing, maybe this is a clue. I use this code to load the subview during applicationDidFinishLaunching:
In the XIB file (which I have examined in both Interface Builder and in a text editor) the progress bar is 280 pixels wide. But when the view opens, it has somehow been adjusted to maybe half that width. Also, the background image of the view is default.png. Instead of appearing right on top of the default image, it is shoved up about 10 pixels, leaving a white bar across the bottom of the screen.
Maybe that's a separate issue, maybe not.
eclipse - Eclipse 进度视图停止按钮监听器
我开发了一个 Eclipse 插件,并创建了一个进度视图来指示工作的运行位置。一切正常,但我有一个问题。当我制作这个视图时,它上面出现了一个停止按钮。但我还没有找到任何听众来控制这一点。但最好的应该是,如果在停止按钮的视图中有一个暂停按钮。请给我一些想法!谢谢!
iphone - 如何在 UIToolbar 中的 UIProgressView 上方添加标签?
我有一个 UIToolbar 我已经成功放置了一个 UIProgressView 。但是,我看到一些应用程序在 UIProgressView 上方包含一个小标签,它告诉用户程序在哪里取得了进展——例如下载文件。然而,这似乎不能在 UI Builder 中完成。关于在工具栏中添加标签的最佳方法有什么想法吗?这是我感兴趣的:
iphone - 如何增加 UIProgressView 的高度
我正在UIProgressView
从nib
. 我想增加它的高度,但它固定为 9。因为iPad
我需要增加它的高度。怎么做?