commit 7df94f5e5bd49ee46dc7ef853aeb277b5b4a33ca Author: 230417 <230417@epvc.pt> Date: Tue Nov 18 15:26:22 2025 +0000 first commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..aa724b7 --- /dev/null +++ b/.gitignore @@ -0,0 +1,15 @@ +*.iml +.gradle +/local.properties +/.idea/caches +/.idea/libraries +/.idea/modules.xml +/.idea/workspace.xml +/.idea/navEditor.xml +/.idea/assetWizardSettings.xml +.DS_Store +/build +/captures +.externalNativeBuild +.cxx +local.properties diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..26d3352 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,3 @@ +# Default ignored files +/shelf/ +/workspace.xml diff --git a/.idea/AndroidProjectSystem.xml b/.idea/AndroidProjectSystem.xml new file mode 100644 index 0000000..4a53bee --- /dev/null +++ b/.idea/AndroidProjectSystem.xml @@ -0,0 +1,6 @@ + + + + + \ No newline at end of file diff --git a/.idea/gradle.xml b/.idea/gradle.xml new file mode 100644 index 0000000..b838237 --- /dev/null +++ b/.idea/gradle.xml @@ -0,0 +1,12 @@ + + + + + + \ No newline at end of file diff --git a/.idea/migrations.xml b/.idea/migrations.xml new file mode 100644 index 0000000..f8051a6 --- /dev/null +++ b/.idea/migrations.xml @@ -0,0 +1,10 @@ + + + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..3040d03 --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,10 @@ + + + + + + + + + \ No newline at end of file diff --git a/.idea/runConfigurations.xml b/.idea/runConfigurations.xml new file mode 100644 index 0000000..16660f1 --- /dev/null +++ b/.idea/runConfigurations.xml @@ -0,0 +1,17 @@ + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/app/.gitignore b/app/.gitignore new file mode 100644 index 0000000..42afabf --- /dev/null +++ b/app/.gitignore @@ -0,0 +1 @@ +/build \ No newline at end of file diff --git a/app/build.gradle.kts b/app/build.gradle.kts new file mode 100644 index 0000000..2e5fa22 --- /dev/null +++ b/app/build.gradle.kts @@ -0,0 +1,48 @@ +plugins { + id("com.android.application") + id("com.google.gms.google-services") +} + +android { + namespace = "com.example.smartagenda" + compileSdk = 34 + + defaultConfig { + applicationId = "com.example.smartagenda" + minSdk = 24 + targetSdk = 34 + versionCode = 1 + versionName = "1.0" + } + + buildTypes { + release { + isMinifyEnabled = false + proguardFiles( + getDefaultProguardFile("proguard-android-optimize.txt"), + "proguard-rules.pro" + ) + } + } + + compileOptions { + sourceCompatibility = JavaVersion.VERSION_17 + targetCompatibility = JavaVersion.VERSION_17 + } + + buildFeatures { + viewBinding = true + } +} + +dependencies { + implementation("com.google.firebase:firebase-bom:33.1.2") + implementation("com.google.firebase:firebase-analytics") + implementation("com.google.firebase:firebase-auth") + implementation("com.google.firebase:firebase-database") + + implementation("androidx.appcompat:appcompat:1.7.0") + implementation("com.google.android.material:material:1.12.0") + implementation("androidx.constraintlayout:constraintlayout:2.1.4") +} + diff --git a/app/google-services.json b/app/google-services.json new file mode 100644 index 0000000..88d5f53 --- /dev/null +++ b/app/google-services.json @@ -0,0 +1,29 @@ +{ + "project_info": { + "project_number": "311102842144", + "project_id": "smartagenda-c25c8", + "storage_bucket": "smartagenda-c25c8.firebasestorage.app" + }, + "client": [ + { + "client_info": { + "mobilesdk_app_id": "1:311102842144:android:4f5f45a5cb606ad290a345", + "android_client_info": { + "package_name": "com.example.smartagenda" + } + }, + "oauth_client": [], + "api_key": [ + { + "current_key": "AIzaSyD7XVk06YINJdqo5omE2jnNpNu8S0E0MF0" + } + ], + "services": { + "appinvite_service": { + "other_platform_oauth_client": [] + } + } + } + ], + "configuration_version": "1" +} \ No newline at end of file diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro new file mode 100644 index 0000000..481bb43 --- /dev/null +++ b/app/proguard-rules.pro @@ -0,0 +1,21 @@ +# Add project specific ProGuard rules here. +# You can control the set of applied configuration files using the +# proguardFiles setting in build.gradle. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} + +# Uncomment this to preserve the line number information for +# debugging stack traces. +#-keepattributes SourceFile,LineNumberTable + +# If you keep the line number information, uncomment this to +# hide the original source file name. +#-renamesourcefileattribute SourceFile \ No newline at end of file diff --git a/app/src/androidTest/java/com/example/smartagenda/ExampleInstrumentedTest.java b/app/src/androidTest/java/com/example/smartagenda/ExampleInstrumentedTest.java new file mode 100644 index 0000000..9254f48 --- /dev/null +++ b/app/src/androidTest/java/com/example/smartagenda/ExampleInstrumentedTest.java @@ -0,0 +1,26 @@ +package com.example.smartagenda; + +import android.content.Context; + +import androidx.test.platform.app.InstrumentationRegistry; +import androidx.test.ext.junit.runners.AndroidJUnit4; + +import org.junit.Test; +import org.junit.runner.RunWith; + +import static org.junit.Assert.*; + +/** + * Instrumented test, which will execute on an Android device. + * + * @see Testing documentation + */ +@RunWith(AndroidJUnit4.class) +public class ExampleInstrumentedTest { + @Test + public void useAppContext() { + // Context of the app under test. + Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); + assertEquals("com.example.smartagenda", appContext.getPackageName()); + } +} \ No newline at end of file diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml new file mode 100644 index 0000000..551e598 --- /dev/null +++ b/app/src/main/AndroidManifest.xml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + \ No newline at end of file diff --git a/app/src/main/java/com/example/smartagenda/MainActivity.java b/app/src/main/java/com/example/smartagenda/MainActivity.java new file mode 100644 index 0000000..3bfd37d --- /dev/null +++ b/app/src/main/java/com/example/smartagenda/MainActivity.java @@ -0,0 +1,58 @@ +package com.example.smartagenda; + +import android.os.Bundle; +import android.view.MenuItem; +import androidx.annotation.NonNull; +import androidx.appcompat.app.ActionBarDrawerToggle; +import androidx.appcompat.app.AppCompatActivity; +import androidx.drawerlayout.widget.DrawerLayout; +import com.google.android.material.appbar.MaterialToolbar; +import com.google.android.material.navigation.NavigationView; + +public class MainActivity extends AppCompatActivity { + + private DrawerLayout drawerLayout; + private NavigationView navigationView; + private MaterialToolbar topAppBar; + private ActionBarDrawerToggle toggle; + + @Override + protected void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + setContentView(R.layout.activity_main); + + // Ligações aos componentes do layout + drawerLayout = findViewById(R.id.drawerLayout); + navigationView = findViewById(R.id.navigationView); + topAppBar = findViewById(R.id.topAppBar); + + // Configurar o botão de menu (☰) + toggle = new ActionBarDrawerToggle(this, drawerLayout, topAppBar, + R.string.navigation_drawer_open, R.string.navigation_drawer_close); + drawerLayout.addDrawerListener(toggle); + toggle.syncState(); + + // Lidar com cliques no menu lateral + navigationView.setNavigationItemSelectedListener(new NavigationView.OnNavigationItemSelectedListener() { + @Override + public boolean onNavigationItemSelected(@NonNull MenuItem item) { + + int id = item.getItemId(); + + if (id == R.id.nav_marcar) { + // Exemplo: ação ao clicar em "Marcar Corte" + topAppBar.setTitle("Marcar Corte"); + } else if (id == R.id.nav_agendamentos) { + topAppBar.setTitle("Meus Agendamentos"); + } else if (id == R.id.nav_perfil) { + topAppBar.setTitle("Perfil"); + } else if (id == R.id.nav_config) { + topAppBar.setTitle("Configurações"); + } + + drawerLayout.closeDrawers(); + return true; + } + }); + } +} diff --git a/app/src/main/java/com/example/smartagenda/ui/AgendamentosFragment.java b/app/src/main/java/com/example/smartagenda/ui/AgendamentosFragment.java new file mode 100644 index 0000000..17e8ce6 --- /dev/null +++ b/app/src/main/java/com/example/smartagenda/ui/AgendamentosFragment.java @@ -0,0 +1,19 @@ +package com.example.smartagenda.ui; + +import android.os.Bundle; +import android.view.LayoutInflater; +import android.view.View; +import android.view.ViewGroup; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; +import androidx.fragment.app.Fragment; +import com.example.smartagenda.R; + +public class AgendamentosFragment extends Fragment { + + @Nullable + @Override + public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { + return inflater.inflate(R.layout.fragment_agendamentos, container, false); + } +} diff --git a/app/src/main/java/com/example/smartagenda/ui/ConfiguracoesFragment.java b/app/src/main/java/com/example/smartagenda/ui/ConfiguracoesFragment.java new file mode 100644 index 0000000..ea76849 --- /dev/null +++ b/app/src/main/java/com/example/smartagenda/ui/ConfiguracoesFragment.java @@ -0,0 +1,19 @@ +package com.example.smartagenda.ui; + +import android.os.Bundle; +import android.view.LayoutInflater; +import android.view.View; +import android.view.ViewGroup; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; +import androidx.fragment.app.Fragment; +import com.example.smartagenda.R; + +public class ConfiguracoesFragment extends Fragment { + + @Nullable + @Override + public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { + return inflater.inflate(R.layout.fragment_configuracoes, container, false); + } +} diff --git a/app/src/main/java/com/example/smartagenda/ui/MarcarCorteFragment.java b/app/src/main/java/com/example/smartagenda/ui/MarcarCorteFragment.java new file mode 100644 index 0000000..86c1601 --- /dev/null +++ b/app/src/main/java/com/example/smartagenda/ui/MarcarCorteFragment.java @@ -0,0 +1,19 @@ +package com.example.smartagenda.ui; + +import android.os.Bundle; +import android.view.LayoutInflater; +import android.view.View; +import android.view.ViewGroup; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; +import androidx.fragment.app.Fragment; +import com.example.smartagenda.R; + +public class MarcarCorteFragment extends Fragment { + + @Nullable + @Override + public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { + return inflater.inflate(R.layout.fragment_marcar_corte, container, false); + } +} diff --git a/app/src/main/java/com/example/smartagenda/ui/PerfilFragment.java b/app/src/main/java/com/example/smartagenda/ui/PerfilFragment.java new file mode 100644 index 0000000..fe8d5f7 --- /dev/null +++ b/app/src/main/java/com/example/smartagenda/ui/PerfilFragment.java @@ -0,0 +1,19 @@ +package com.example.smartagenda.ui; + +import android.os.Bundle; +import android.view.LayoutInflater; +import android.view.View; +import android.view.ViewGroup; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; +import androidx.fragment.app.Fragment; +import com.example.smartagenda.R; + +public class PerfilFragment extends Fragment { + + @Nullable + @Override + public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { + return inflater.inflate(R.layout.fragment_perfil, container, false); + } +} diff --git a/app/src/main/res/drawable/ic_launcher_background.xml b/app/src/main/res/drawable/ic_launcher_background.xml new file mode 100644 index 0000000..07d5da9 --- /dev/null +++ b/app/src/main/res/drawable/ic_launcher_background.xml @@ -0,0 +1,170 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/app/src/main/res/drawable/ic_launcher_foreground.xml b/app/src/main/res/drawable/ic_launcher_foreground.xml new file mode 100644 index 0000000..2b068d1 --- /dev/null +++ b/app/src/main/res/drawable/ic_launcher_foreground.xml @@ -0,0 +1,30 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/app/src/main/res/layout/activity_main.xml b/app/src/main/res/layout/activity_main.xml new file mode 100644 index 0000000..fae331d --- /dev/null +++ b/app/src/main/res/layout/activity_main.xml @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + diff --git a/app/src/main/res/layout/fragment_agendamentos.xml b/app/src/main/res/layout/fragment_agendamentos.xml new file mode 100644 index 0000000..d798f82 --- /dev/null +++ b/app/src/main/res/layout/fragment_agendamentos.xml @@ -0,0 +1,14 @@ + + + + + diff --git a/app/src/main/res/layout/fragment_configuracoes.xml b/app/src/main/res/layout/fragment_configuracoes.xml new file mode 100644 index 0000000..dd17d19 --- /dev/null +++ b/app/src/main/res/layout/fragment_configuracoes.xml @@ -0,0 +1,14 @@ + + + + + diff --git a/app/src/main/res/layout/fragment_marcar_corte.xml b/app/src/main/res/layout/fragment_marcar_corte.xml new file mode 100644 index 0000000..7f5ec27 --- /dev/null +++ b/app/src/main/res/layout/fragment_marcar_corte.xml @@ -0,0 +1,14 @@ + + + + + diff --git a/app/src/main/res/layout/fragment_perfil.xml b/app/src/main/res/layout/fragment_perfil.xml new file mode 100644 index 0000000..631b5a3 --- /dev/null +++ b/app/src/main/res/layout/fragment_perfil.xml @@ -0,0 +1,14 @@ + + + + + diff --git a/app/src/main/res/layout/nav_header.xml b/app/src/main/res/layout/nav_header.xml new file mode 100644 index 0000000..5de2928 --- /dev/null +++ b/app/src/main/res/layout/nav_header.xml @@ -0,0 +1,26 @@ + + + + + + + + diff --git a/app/src/main/res/menu/drawer_menu.xml b/app/src/main/res/menu/drawer_menu.xml new file mode 100644 index 0000000..5d73655 --- /dev/null +++ b/app/src/main/res/menu/drawer_menu.xml @@ -0,0 +1,18 @@ + + + + + + diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml new file mode 100644 index 0000000..6f3b755 --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml new file mode 100644 index 0000000..6f3b755 --- /dev/null +++ b/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher.webp b/app/src/main/res/mipmap-hdpi/ic_launcher.webp new file mode 100644 index 0000000..c209e78 Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher.webp differ diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp new file mode 100644 index 0000000..b2dfe3d Binary files /dev/null and b/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher.webp b/app/src/main/res/mipmap-mdpi/ic_launcher.webp new file mode 100644 index 0000000..4f0f1d6 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher.webp differ diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp new file mode 100644 index 0000000..62b611d Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher.webp b/app/src/main/res/mipmap-xhdpi/ic_launcher.webp new file mode 100644 index 0000000..948a307 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher.webp differ diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp new file mode 100644 index 0000000..1b9a695 Binary files /dev/null and b/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp b/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp new file mode 100644 index 0000000..28d4b77 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp differ diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp new file mode 100644 index 0000000..9287f50 Binary files /dev/null and b/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp b/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp new file mode 100644 index 0000000..aa7d642 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp differ diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp new file mode 100644 index 0000000..9126ae3 Binary files /dev/null and b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp differ diff --git a/app/src/main/res/values-night/themes.xml b/app/src/main/res/values-night/themes.xml new file mode 100644 index 0000000..c0520d8 --- /dev/null +++ b/app/src/main/res/values-night/themes.xml @@ -0,0 +1,7 @@ + + + + \ No newline at end of file diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml new file mode 100644 index 0000000..c8524cd --- /dev/null +++ b/app/src/main/res/values/colors.xml @@ -0,0 +1,5 @@ + + + #FF000000 + #FFFFFFFF + \ No newline at end of file diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml new file mode 100644 index 0000000..61cb58e --- /dev/null +++ b/app/src/main/res/values/strings.xml @@ -0,0 +1,5 @@ + + SmartAgenda + Abrir menu + Fechar menu + diff --git a/app/src/main/res/values/themes.xml b/app/src/main/res/values/themes.xml new file mode 100644 index 0000000..22c4a7a --- /dev/null +++ b/app/src/main/res/values/themes.xml @@ -0,0 +1,9 @@ + + + + +