qdrzwd / VideoRecorder

android视频录制,模仿微视,支持按下录制、抬起暂停。进度条断点显示。
Apache License 2.0
1.8k stars 563 forks source link

自定义progress中有一点问题布局异常但可以运行,我找到个人解决办法,不知道有没有好的办法请后面追加: #51

Open geogie opened 8 years ago

geogie commented 8 years ago

DisplayMetrics dm = new DisplayMetrics(); ((Activity) paramContext).getWindowManager().getDefaultDisplay().getMetrics(dm); perPixel = dm.widthPixels / countRecorderTime; 上面这段会导致在布局初始化的时候:报布局异常 这个在加载布局前获取:widthPixels 我是在工具类中widthPixels 初始化,在再自定义progress中用,就不会再提示了!!!! 如果有其他好的解决办法,请追加