Skip to content

[FEATURE] アラーム・振動機能 #10

Description

@jellYTM

💡 機能の概要

  • アラーム(音と振動)それぞれの機能の作成
  • デバック用のダミーボタンの作成

📋 実装の詳細

main ブランチから feat_#10 のブランチを切って開発を行ってください
以下のような仮のページにボタンを2つ作って動作確認

class NotificationTimerPage extends StatelessWidget{
  // 前略
  void activateNotificationTimer({int minutes = 0, int seconds = 0}) {
    // ここに通知を設定するコードを追加
  }

  // 中略
 @override
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text("通知テスト"),
      ),
      body: Center(
        child: Column(
          mainAxisAlignment: MainAxisAlignment.center,
          children: <Widget>[
            ElevatedButton(
              onPressed: () {
                activateNotificationTimer(minutes: 5, seconds :0);
              },
              child: const Text('5分後に通知'),
            ),
            ElevatedButton(
              onPressed: () {
                activateNotificationTimer(seconds :10);
              },
              child: const Text('10秒後に通知'),
            ),
          ],
        ),
      ),
    );
  }
  // 後略
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions