v1.0.4 - 날짜 옆 근무 뱃지 원형 정밀 보정, 앱 안정성 설정 아이콘 및 색상 개편

This commit is contained in:
sanjeok77
2026-08-14 09:39:43 +09:00
parent f5b2f72a0b
commit d245aeb7d5
9 changed files with 83 additions and 38 deletions
BIN
View File
Binary file not shown.
+2 -2
View File
@@ -20,8 +20,8 @@ android {
applicationId = "com.example.shiftalarm"
minSdk = 26
targetSdk = 35
versionCode = 103
versionName = "1.0.3"
versionCode = 104
versionName = "1.0.4"
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
}
@@ -150,13 +150,25 @@ class CalendarAdapter(
holder.shiftChar.visibility = View.GONE
holder.tvShiftSmall.visibility = View.VISIBLE
holder.tvShiftSmall.text = shiftAbbreviation
holder.tvShiftSmall.textSize = if (shiftAbbreviation.length > 1) 7.5f else 9.5f
holder.tvShiftSmall.setTypeface(null, android.graphics.Typeface.BOLD)
val smallBg = ContextCompat.getDrawable(context, R.drawable.bg_shift_stroke_v4) as? android.graphics.drawable.GradientDrawable
smallBg?.mutate()
smallBg?.setStroke(dpToPx(context, 1.2f), shiftColor)
smallBg?.setColor(if (isToday) shiftColor else Color.TRANSPARENT)
holder.tvShiftSmall.background = smallBg
holder.tvShiftSmall.setTextColor(if (isToday && (item.shift == "야간" || item.shift == "교육")) Color.WHITE else shiftColor)
if (item.shift == "반월" || item.shift == "반년") {
holder.tvShiftSmall.text = if (item.shift == "반월") "" else ""
holder.tvShiftSmall.setTextColor(ContextCompat.getColor(context, R.color.black))
holder.tvShiftSmall.background = ContextCompat.getDrawable(context, R.drawable.bg_shift_half_red)
} else if (isToday) {
val smallBg = ContextCompat.getDrawable(context, R.drawable.bg_shift_solid_v4)?.constantState?.newDrawable()?.mutate() as? android.graphics.drawable.GradientDrawable
smallBg?.setColor(shiftColor)
holder.tvShiftSmall.background = smallBg
holder.tvShiftSmall.setTextColor(if (item.shift == "주간" || item.shift == "석간") ContextCompat.getColor(context, R.color.black) else Color.WHITE)
} else {
val smallBg = ContextCompat.getDrawable(context, R.drawable.bg_shift_stroke_v4)?.constantState?.newDrawable()?.mutate() as? android.graphics.drawable.GradientDrawable
smallBg?.setStroke(dpToPx(context, 1.2f), shiftColor)
smallBg?.setColor(Color.TRANSPARENT)
holder.tvShiftSmall.background = smallBg
holder.tvShiftSmall.setTextColor(shiftColor)
}
} else {
// When day has NO memo: standard large centered shift circle
holder.shiftChar.visibility = View.VISIBLE
+9
View File
@@ -0,0 +1,9 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#FF000000"
android:pathData="M16.67,4H15V2H9v2H7.33C6.6,4 6,4.6 6,5.33v15.33C6,21.4 6.6,22 7.33,22h9.33c0.74,0 1.34,-0.6 1.34,-1.33V5.33C18,4.6 17.4,4 16.67,4zM11,20v-5.5H9L13,7v5.5h2L11,20z"/>
</vector>
+12
View File
@@ -0,0 +1,12 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#FF000000"
android:pathData="M7,14H5v5h5v-2H7v-3zm-2,-4h2V7h3V5H5v5zm12,7h-3v2h5v-5h-2v3zM14,5v2h3v3h2V5h-5z"/>
<path
android:fillColor="#FF000000"
android:pathData="M12,8.5c-1.93,0 -3.5,1.57 -3.5,3.5s1.57,3.5 3.5,3.5 3.5,-1.57 3.5,-3.5 -1.57,-3.5 -3.5,-3.5zm0,5.5c-1.1,0 -2,-0.9 -2,-2s0.9,-2 2,-2 2,0.9 2,2 -0.9,2 -2,2z"/>
</vector>
@@ -175,8 +175,8 @@
android:layout_width="20dp"
android:layout_height="20dp"
android:layout_gravity="center"
android:src="@drawable/ic_alarm"
app:tint="@color/shift_red"/>
android:src="@drawable/ic_battery"
app:tint="#34C759"/>
</FrameLayout>
<LinearLayout
@@ -232,7 +232,7 @@
android:layout_height="20dp"
android:layout_gravity="center"
android:src="@drawable/ic_alarm"
app:tint="@color/primary"/>
app:tint="#007AFF"/>
</FrameLayout>
<LinearLayout
@@ -344,8 +344,8 @@
android:layout_width="20dp"
android:layout_height="20dp"
android:layout_gravity="center"
android:src="@drawable/ic_bell"
app:tint="@color/primary"/>
android:src="@drawable/ic_fullscreen_intent"
app:tint="#AF52DE"/>
</FrameLayout>
<LinearLayout
@@ -401,7 +401,7 @@
android:layout_height="20dp"
android:layout_gravity="center"
android:src="@drawable/ic_settings"
app:tint="@color/text_tertiary"/>
app:tint="#FF9500"/>
</FrameLayout>
<TextView
+4 -6
View File
@@ -31,17 +31,15 @@
<!-- Small Shift Badge next to Day Number (shown when day has memo) -->
<TextView
android:id="@+id/tvShiftSmall"
android:layout_width="wrap_content"
android:layout_height="16dp"
android:minWidth="16dp"
android:layout_marginStart="4dp"
android:layout_width="18dp"
android:layout_height="18dp"
android:layout_marginStart="3dp"
android:gravity="center"
android:includeFontPadding="false"
android:text="주"
android:textSize="9.5sp"
android:textStyle="bold"
android:textColor="@color/text_primary"
android:background="@drawable/bg_shift_stroke_v4"
android:paddingHorizontal="3dp"
android:visibility="gone"/>
</LinearLayout>
+27 -13
View File
@@ -6,17 +6,20 @@ import shutil
token = "e3b515eaa0a6683c921ca3bf718e281ed30a6075"
owner_repo = "sanjeok77/ShiftRing"
tag = "v1.0.3"
title = "v1.0.3 - 하루 메모 4줄 확장 & 날짜 옆 근무 뱃지 배치 및 알람 추가 시 볼륨 최대치 보정"
body = """## 🚀 ShiftRing v1.0.3 릴리즈
tag = "v1.0.4"
title = "v1.0.4 - 날짜 옆 근무 뱃지 완벽한 원형/글자 크기 정밀 보정 & 설정 권한 아이콘/색상 시각화 개선"
body = """## 🚀 ShiftRing v1.0.4 릴리즈
### 🌟 주요 변경 및 개선 사항
1. **하루 메모 4줄 확장 및 날짜 옆 근무 뱃지 직관 배치**:
- 메모가 작성된 날짜의 경우 기존 중앙 큰 동그라미 대신 **날짜 숫자 바로 옆에 미니멀한 근무 뱃지(주/석/야/휴 등)**를 컴팩트하게 표시
- 달력 셀 중앙 영역을 메모 텍스트에 온전히 할애하여 **최대 4줄까지 메모 내용이 깔끔하게 표시**되도록 가독성 대폭 향상
- 메모가 없는 날짜는 기존대로 중앙에 크고 또렷한 20sp 근무 원형 표시 유지
2. **알람 추가 시 시스템 알람 스트림 볼륨 최대치 자동 보정**:
- 알람 추가 또는 알람 스트림 볼륨이 0(무음)으로 되어 있는 경우, 시스템 알람 볼륨(`STREAM_ALARM`)을 자동으로 최대치로 설정하여 소리가 안 나는 현상 방지
1. **날짜 옆 근무 뱃지 원형 왜곡 방지 및 글자 가독성 정밀 보정**:
- 메모가 있는 날짜의 상단 근무 뱃지(`tvShiftSmall`)를 정원(18dp × 18dp)으로 고정하여 찌그러짐 현상 완벽 방지
- 폰트 패딩 제거(`includeFontPadding=false`) 및 텍스트 크기 정밀 조정으로 '주/석/야/휴/월/연/교''주맞/야맞/반월' 텍스트가 잘림 없이 100% 선명하게 표시
2. **앱 안정성 설정 (필수) 항목별 아이콘 및 테마 색상 개편**:
- 배터리 최적화 제외: 배터리 전용 아이콘(`ic_battery`) + 에메랄드 그린(`#34C759`)
- 정확한 알람 허용: 정밀 시계 아이콘(`ic_alarm`) + One UI 블루(`#007AFF`)
- 전체화면 알림 허용: 전체화면 인텐트 전용 아이콘(`ic_fullscreen_intent`) + 비비드 퍼플(`#AF52DE`)
- 시스템 전체 권한 설정: 시스템 톱니바퀴 아이콘(`ic_settings`) + 앰버 오렌지(`#FF9500`)
- 각 권한의 성격과 상태를 한눈에 직관적으로 구분할 수 있도록 시각 계층 대폭 강화
3. **Android 14/15 호환 및 정식 서명키(release.jks) 적용**"""
apk_path = "app/build/outputs/apk/release/app-release.apk"
@@ -30,7 +33,7 @@ print(f"Using APK at: {apk_path}")
url = f"https://git.webpluss.net/api/v1/repos/{owner_repo}/releases"
headers = {"Authorization": f"token {token}", "Content-Type": "application/json"}
data = json.dumps({"tag_name": tag, "name": title, "body": body, "draft": False, "prerelease": False}).encode()
data = json.dumps({"tag_name": tag, "name": title, "body": body, "draft": False, "prerelease": False}).encode('utf-8')
req = urllib.request.Request(url, data=data, headers=headers, method="POST")
with urllib.request.urlopen(req) as response:
result = json.loads(response.read())
@@ -55,14 +58,25 @@ print("Updated app.apk at project root.")
# Update version.json
v_info = {
"versionCode": 103,
"versionName": "1.0.3",
"versionCode": 104,
"versionName": "1.0.4",
"apkUrl": direct_url,
"changelog": "v1.0.3: 하루 메모 4줄 확장 & 날짜 옆 근무 뱃지 배치, 알람 추가 시 볼륨 최대치 자동 보정",
"changelog": "v1.0.4: 날짜 옆 근무 뱃지 원형 정밀 보정 & 글자 가독성 개선, 앱 안정성 설정 아이콘 및 색상 시각화",
"forceUpdate": False
}
with open("version.json", "w", encoding="utf-8") as f:
json.dump(v_info, f, ensure_ascii=False, indent=2)
print(f"Updated version.json with apkUrl: {direct_url}")
# Git commit and push cleanly in UTF-8
git_path = r"C:\Users\work\AppData\Roaming\MobaXterm\slash\mx86_64b\bin"
os.environ["PATH"] = git_path + os.pathsep + os.environ.get("PATH", "")
commit_msg = "v1.0.4 - 날짜 옆 근무 뱃지 원형 정밀 보정, 앱 안정성 설정 아이콘 및 색상 개편"
subprocess.run(["git", "add", "."], check=True)
subprocess.run(["git", "commit", "-m", commit_msg], check=True)
subprocess.run(["git", "push", "origin", "main"], check=True)
print("Git commit and push completed successfully!")
print(f"Release {tag} process finished!")
+4 -4
View File
@@ -1,7 +1,7 @@
{
"versionCode": 103,
"versionName": "1.0.3",
"apkUrl": "https://git.webpluss.net/attachments/90c3757b-d618-47a2-9071-260769fae8e7",
"changelog": "v1.0.3: 하루 메모 4줄 확장 & 날짜 옆 근무 뱃지 배치, 알람 추가 시 볼륨 최대치 자동 보정",
"versionCode": 104,
"versionName": "1.0.4",
"apkUrl": "https://git.webpluss.net/attachments/017b75f6-07a5-468f-8694-83345c9692e3",
"changelog": "v1.0.4: 날짜 옆 근무 뱃지 원형 정밀 보정 & 글자 가독성 개선, 앱 안정성 설정 아이콘 및 색상 시각화",
"forceUpdate": false
}