InteractivePlayerView-master

所属分类:Windows编程
开发工具:Java
文件大小:1322KB
下载次数:1
上传日期:2016-08-23 15:13:37
上 传 者半盏流年
说明:  InteractivePlayerView-master app源码,源码精简,亲测可用,适合初学者研究
(InteractivePlayerView-master app source code, source code to streamline, pro-test available for beginners research)

文件列表:
.idea (0, 2015-08-18)
.idea\.name (21, 2015-08-18)
.idea\compiler.xml (686, 2015-08-18)
.idea\copyright (0, 2015-08-18)
.idea\copyright\profiles_settings.xml (74, 2015-08-18)
.idea\gradle.xml (661, 2015-08-18)
.idea\misc.xml (2677, 2015-08-18)
.idea\modules.xml (492, 2015-08-18)
.idea\runConfigurations.xml (564, 2015-08-18)
.idea\vcs.xml (164, 2015-08-18)
InteractivePlayerView.iml (952, 2015-08-18)
app (0, 2015-08-18)
app\app.iml (7772, 2015-08-18)
app\build.gradle (631, 2015-08-18)
app\proguard-rules.pro (668, 2015-08-18)
app\src (0, 2015-08-18)
app\src\androidTest (0, 2015-08-18)
app\src\androidTest\java (0, 2015-08-18)
app\src\androidTest\java\co (0, 2015-08-18)
app\src\androidTest\java\co\mobiwise (0, 2015-08-18)
app\src\androidTest\java\co\mobiwise\interactiveplayerview (0, 2015-08-18)
app\src\androidTest\java\co\mobiwise\interactiveplayerview\ApplicationTest.java (364, 2015-08-18)
app\src\main (0, 2015-08-18)
app\src\main\AndroidManifest.xml (631, 2015-08-18)
app\src\main\java (0, 2015-08-18)
app\src\main\java\co (0, 2015-08-18)
app\src\main\java\co\mobiwise (0, 2015-08-18)
app\src\main\java\co\mobiwise\interactiveplayerview (0, 2015-08-18)
app\src\main\java\co\mobiwise\interactiveplayerview\MainTest.java (1689, 2015-08-18)
app\src\main\res (0, 2015-08-18)
app\src\main\res\drawable (0, 2015-08-18)
app\src\main\res\drawable\blurbg.png (285466, 2015-08-18)
app\src\main\res\drawable\circle.xml (271, 2015-08-18)
app\src\main\res\drawable\icon_arrow_down.png (735, 2015-08-18)
app\src\main\res\drawable\icon_back.png (3135, 2015-08-18)
app\src\main\res\drawable\icon_forward.png (2811, 2015-08-18)
... ...

# InteractivePlayerView [![Join the chat at https://gitter.im/iammert/InteractivePlayerView](https://img.shields.io/badge/GITTER-join%20chat-green.svg)](https://gitter.im/iammert/InteractivePlayerView) [![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-InteractivePlayerView-green.svg?style=flat)](https://android-arsenal.com/details/1/2332) Custom android music player view. # Screen Check it on [youtube](https://www.youtube.com/watch?v=9cN5PCjUioM) # Usage(XML) Define it in your xml file. ```xml ``` **IMPORTANT** : I designed shuffle, like and replay icons for my demo app. You can create your by using [Flat Icon](http://flaticon.com) website. Or, if you want to use mine instead of creating new icon set, then you can download my action set from [here](https://github.com/iammert/InteractivePlayerView/blob/master/demoIcons.zip). Find view and set necessary values. ```java InteractivePlayerView ipv = (InteractivePlayerView) findViewById(R.id.ipv); ipv.setMax(123); // music duration in seconds. ipv.setOnActionClickedListener(new OnActionClickedListener() { @Override public void onActionClicked(int id) { switch (id){ case 1: //Called when 1. action is clicked. break; case 2: //Called when 2. action is clicked. break; case 3: //Called when 3. action is clicked. break; default: break; } } }); ``` Start and stop depends on your player. ```java ipv.start(); ipv.stop(); ``` # Usage (Java) ```java ipv.setCoverDrawable(R.drawable.imagetest); ipv.setActionOneImage(R.drawable.shuffle_selected, R.drawable.shuffle_unselected); ipv.setActionTwoImage(R.drawable.like_selected, R.drawable.like_unselected); ipv.setActionThreeImage(R.drawable.replay_selected, R.drawable.replay_unselected); ipv.setProgressEmptyColor(Color.GRAY); ipv.setProgressEmptyColor(Color.BLACK); ``` # Useful methods ```java //Loads image from url (By Picasso) ipv.setCoverURL("http://abc.xyz/1.png"); ``` ```java //edit your current progress ipv.setProgress(12); int currentProgress = ipv.getProgress(); ``` ```java //Check if any action selected or not. Or edit. boolean isSelected = ipv.isAction1Selected(); ipv.setAction1Selected(true); ``` ```java //Check if ipv is playing ipv.isPlaying(); ``` # Import Project build.gradle ``` repositories { maven { url "https://jitpack.io" } } ``` Module build.gradle ``` dependencies { compile 'com.github.iammert:InteractivePlayerView:8fd08a6d8b' } ``` # Design [Here is original design](https://www.pinterest.com/pin/4001871168666***878/) # Library used [Picasso by Square](http://square.github.io/picasso/) License -------- Copyright 2015 Mert Simsek. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

近期下载者

相关文件


收藏者