Skip to content

Commit 0194a55

Browse files
author
paroca72
committed
Some font adjustment
1 parent f72c803 commit 0194a55

File tree

3 files changed

+4
-5
lines changed

3 files changed

+4
-5
lines changed

.idea/misc.xml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/src/main/java/com/sccomponents/playerbutton/demo/MainActivity.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ protected void onCreate(Bundle savedInstanceState) {
3030
Uri defaultRintoneUri = RingtoneManager
3131
.getActualDefaultRingtoneUri(this.getApplicationContext(), RingtoneManager.TYPE_RINGTONE);
3232
player.setSource(defaultRintoneUri.toString());
33-
player.setSeekBar(seekBar);
3433
}
3534

3635
private void checkRunTimePermission() {

library/src/main/java/com/sccomponents/playerbutton/ScPlayerButton.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ public class ScPlayerButton extends View {
4747
private static final String PERMISSION = "RECORD_AUDIO";
4848

4949
private static final int UPDATE_FREQUENCY = 10; // Hertz
50-
private static final float FONT_SIZE = 32.0f;
50+
private static final float FONT_SIZE = 11.0f;
5151
private static final float VOLUME = 0.7f;
5252

5353

@@ -147,8 +147,8 @@ private void init(Context context, AttributeSet attrs, int defStyle) {
147147
this.mColor = attrArray.getColor(
148148
R.styleable.ScPlayerButton_scc_color, Color.parseColor(ScPlayerButton.FOREGROUND_COLOR));
149149
this.mFontSize = attrArray.getDimension(
150-
R.styleable.ScPlayerButton_scc_font_size, ScPlayerButton.FONT_SIZE);
151-
this.mVolume = attrArray.getDimension(
150+
R.styleable.ScPlayerButton_scc_font_size, this.dipToPixel(ScPlayerButton.FONT_SIZE));
151+
this.mVolume = attrArray.getFloat(
152152
R.styleable.ScPlayerButton_scc_volume, ScPlayerButton.VOLUME);
153153

154154
// Recycle

0 commit comments

Comments
 (0)