Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

[Bug] File action sheet shows no actions at all for locked files

オープン 初心者向け
#17,845 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
1/5
見積もり時間
1時間未満
初心者へのやさしさ
86/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
android, kotlin
領域
mobile

調査の方向性

FileActionsBottomSheet.handleState()から始めて、displayActions()とdisplayLockInfo()がシートに行を追加する方法を調べます。issueでは、アクションがスキップされる原因となる呼び出し順序を特定し、ロック情報より先にアクションを表示することを提案しています。ロックされたファイルに通常のアクションとロック情報の両方が表示されれば完了です。payloadにはテストファイル名がありません。

索引モデルが issue の本文から書いたものです。

説明

Steps to reproduce

  1. Lock a file (e.g. open a document in the Text or OnlyOffice app, or use "Lock file" from another client).
  2. In the Android app, open the folder that contains the locked file.
  3. Tap the three-dot menu of that file.

Actual behaviour

The bottom sheet shows the file name and a "Locked by the app …" row, but no actions at all — not even edit, rename, download or delete. The sheet is short and cannot be expanded by dragging.

Expected behaviour

The regular action list is shown, plus the lock information row.

Cause

FileActionsBottomSheet.handleState() calls displayLockInfo() before displayActions():

if (state.lockInfo != null) {
    displayLockInfo(state.lockInfo)
}
displayActions(state.titleFile, state.actions)

displayActions() starts with if (binding.fileActionsList.isNotEmpty()) return, so as soon as the lock row has been appended, every action is skipped. Only the lock row ends up in the sheet.

Suggested fix

Render the actions first and append the lock info afterwards:

displayActions(state.titleFile, state.actions)
if (state.lockInfo != null) {
    displayLockInfo(state.lockInfo)
}

This is also what makes the unlock action reachable — see #17838.

Environment

  • Nextcloud Android 35.0.1 (Play) and current master, Android 16, Pixel 9 Pro
  • Server: Nextcloud 34 (AIO), files_lock 34.0.1

🤖 Generated with Claude Code

主要言語
Kotlin
スター
5.6k
フォーク
2k
平均マージ
2日 11時間
マージ済み PR(30日)
97

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

nextcloud/android のほかの issue

nextcloud/android の issue をすべて見る

似ている issue

Kotlin の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。