main
unknown 6 months ago
parent 01d0f0ae36
commit 425ca9682d
  1. 3
      Justice.csproj
  2. 1
      Platforms/Android/AndroidManifest.xml
  3. 23
      Resources/Splash/log.svg
  4. 112
      Resources/Splash/logos.svg
  5. 9
      Views/MapTimer.xaml
  6. 142
      Views/MapTimer.xaml.cs

@ -61,6 +61,7 @@
<ItemGroup>
<None Remove="Resources\Splash\log.svg" />
<None Remove="Resources\Splash\logos.svg" />
</ItemGroup>
<ItemGroup>
@ -84,7 +85,7 @@
</ItemGroup>
<ItemGroup>
<MauiSplashScreen Include="Resources\Splash\log.svg" Color="#F0F0F0" />
<MauiSplashScreen Include="Resources\Splash\logos.svg" />
</ItemGroup>
<ItemGroup>

@ -21,4 +21,5 @@
<uses-permission android:name="android.permission.WRITE_CALENDAR" />
<uses-permission android:name="android.permission.WRITE_SETTINGS" />
<uses-permission android:name="android.permission.WRITE_SMS" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
</manifest>

@ -1,23 +0,0 @@
<svg width="1024" height="1024" viewBox="0 0 1024 1024" fill="none" xmlns="http://www.w3.org/2000/svg">
<rect width="1024" height="1024" fill="white"/>
<circle cx="516.81" cy="512" r="375.555" fill="white" stroke="black" stroke-width="17.5858"/>
<path d="M313.916 713.725C328.789 705.532 334.223 686.772 326.03 671.899C317.837 657.025 299.078 651.592 284.204 659.784C269.331 667.977 263.897 686.737 272.09 701.61C280.283 716.484 299.047 721.914 313.916 713.725ZM290.122 670.527C299.071 665.598 310.358 668.867 315.287 677.816C320.213 686.76 316.947 698.053 307.998 702.982C299.049 707.911 287.764 704.633 282.838 695.69C277.909 686.741 281.178 675.454 290.122 670.527Z" fill="black"/>
<path d="M219.23 737.73L280.901 703.76C283.604 702.271 284.472 698.657 282.839 695.692C281.205 692.726 277.686 691.528 274.983 693.017L213.312 726.987C210.609 728.476 209.741 732.091 211.374 735.056C213.007 738.021 216.522 739.221 219.23 737.73Z" fill="black"/>
<path d="M311.941 630.104C326.815 621.911 332.248 603.152 324.056 588.278C315.863 573.404 297.103 567.971 282.23 576.164C267.356 584.356 261.923 603.116 270.115 617.989C278.308 632.863 297.073 638.293 311.941 630.104ZM288.147 586.907C297.096 581.977 308.383 585.247 313.313 594.195C318.239 603.139 314.973 614.432 306.024 619.361C297.075 624.29 285.79 621.012 280.864 612.069C275.935 603.12 279.204 591.833 288.147 586.907Z" fill="black"/>
<path d="M184.794 671.985L276.537 621.451C280.558 619.236 282.496 615.032 280.863 612.067C279.23 609.102 274.641 608.493 270.62 610.708L178.876 661.242C174.855 663.457 172.917 667.661 174.55 670.626C176.184 673.591 180.765 674.204 184.794 671.985Z" fill="black"/>
<path d="M244.295 580.159C259.169 571.966 264.602 553.207 256.41 538.333C248.217 523.46 229.458 518.026 214.584 526.219C199.71 534.411 194.277 553.171 202.47 568.045C210.662 582.918 229.427 588.349 244.295 580.159ZM220.501 536.962C229.45 532.033 240.738 535.302 245.667 544.251C250.593 553.194 247.327 564.487 238.378 569.416C229.429 574.345 218.144 571.068 213.218 562.124C208.289 553.175 211.558 541.888 220.501 536.962Z" fill="black"/>
<path d="M157.046 600.064L211.827 569.889C214.228 568.567 214.851 565.087 213.218 562.122C211.585 559.157 208.311 557.824 205.91 559.147L151.129 589.321C148.728 590.644 148.105 594.123 149.738 597.088C151.371 600.053 154.641 601.389 157.046 600.064Z" fill="black"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M364.707 585.175C364.717 585.04 364.722 584.903 364.722 584.765V288.434C364.722 277.486 373.628 268.58 384.576 268.58H658.573C669.521 268.58 678.427 277.486 678.427 288.434V377.651C678.427 380.687 680.886 383.141 683.917 383.141C686.948 383.141 689.407 380.687 689.407 377.651V288.434C689.407 271.43 675.577 257.599 658.573 257.599H384.576C367.572 257.599 353.741 271.436 353.741 288.434V584.765C353.741 585.129 353.776 585.484 353.844 585.828C355.041 601.593 367.448 613.428 383.603 613.428C392.209 613.428 392.209 602.447 383.603 602.447C373.036 602.447 365.237 595.503 364.707 585.175Z" fill="black"/>
<path d="M562.154 368.6H411.73C408.314 368.6 405.542 366.946 405.542 364.9C405.542 362.854 408.314 361.2 411.73 361.2H562.154C565.577 361.2 568.343 362.854 568.343 364.9C568.343 366.946 565.57 368.6 562.154 368.6Z" fill="black" stroke="black" stroke-width="3.70003"/>
<path d="M633.342 324.2H414.543C409.574 324.2 405.542 322.546 405.542 320.5C405.542 318.454 409.574 316.8 414.543 316.8H633.342C638.32 316.8 642.343 318.454 642.343 320.5C642.343 322.546 638.311 324.2 633.342 324.2Z" fill="black" stroke="black" stroke-width="3.70003"/>
<path d="M545.523 412.608H411.073C408.02 412.608 405.542 411.129 405.542 409.301C405.542 407.472 408.02 405.993 411.073 405.993H545.523C548.582 405.993 551.054 407.472 551.054 409.301C551.054 411.129 548.576 412.608 545.523 412.608Z" fill="#C50878" stroke="#C50878" stroke-width="3.30711"/>
<path d="M507.415 456.642H409.567C407.345 456.642 405.542 455.327 405.542 453.701C405.542 452.074 407.345 450.759 409.567 450.759H507.415C509.641 450.759 511.44 452.074 511.44 453.701C511.44 455.327 509.637 456.642 507.415 456.642Z" fill="black" stroke="black" stroke-width="3.69734"/>
<path d="M345.568 426.251L330.255 374.419C329.514 372.482 328.536 370.367 327.421 368.345C326.309 366.321 325.043 364.358 323.659 362.518C322.278 360.681 320.747 358.916 319.11 357.278C317.476 355.647 315.714 354.116 313.87 352.732C312.036 351.354 310.074 350.086 308.043 348.967C306.021 347.855 303.903 346.877 301.747 346.062L250.14 330.827L301.972 315.514C303.903 314.776 306.021 313.801 308.049 312.683C310.08 311.564 312.039 310.296 313.873 308.918C315.717 307.534 317.479 306.003 319.113 304.372C320.75 302.735 322.278 300.972 323.659 299.132C325.046 297.289 326.312 295.326 327.424 293.305C328.54 291.283 329.514 289.165 330.33 287.009L345.568 235.399L360.881 287.231C361.628 289.174 362.602 291.293 363.715 293.308C364.824 295.326 366.092 297.289 367.48 299.135C368.858 300.972 370.389 302.738 372.026 304.375C373.66 306.006 375.422 307.537 377.266 308.921C379.1 310.299 381.062 311.567 383.093 312.686C385.12 313.801 387.236 314.776 389.385 315.589L440.995 330.83L389.167 346.14C387.233 346.88 385.114 347.858 383.09 348.974C381.059 350.092 379.1 351.361 377.262 352.739C375.419 354.123 373.657 355.654 372.023 357.285C370.386 358.922 368.858 360.684 367.477 362.521C366.086 364.371 364.821 366.33 363.712 368.348C362.621 370.329 361.656 372.413 360.843 374.541L345.568 426.251Z" fill="#EFDB5D"/>
<path d="M257.542 472.206L248.883 442.896C248.537 442.006 248.056 440.964 247.511 439.973C246.959 438.972 246.337 438.006 245.656 437.102C244.975 436.193 244.22 435.327 243.417 434.524C242.615 433.722 241.75 432.969 240.841 432.285C239.932 431.602 238.969 430.98 237.973 430.43C236.978 429.88 235.932 429.4 234.872 428.998L205.741 420.399L235.048 411.74C235.932 411.399 236.978 410.916 237.976 410.368C238.969 409.821 239.932 409.199 240.839 408.516C241.75 407.832 242.615 407.079 243.415 406.279C244.22 405.477 244.973 404.61 245.656 403.698C246.335 402.794 246.959 401.828 247.511 400.83C248.059 399.839 248.539 398.797 248.943 397.732L257.542 368.6L266.199 397.91C266.545 398.799 267.026 399.842 267.571 400.833C268.123 401.833 268.745 402.799 269.426 403.703C270.107 404.612 270.862 405.479 271.665 406.282C272.467 407.084 273.332 407.837 274.241 408.521C275.15 409.204 276.113 409.826 277.109 410.376C278.104 410.923 279.15 411.406 280.21 411.807L309.341 420.402L280.034 429.06C279.15 429.402 278.104 429.885 277.106 430.433C276.113 430.98 275.15 431.602 274.243 432.285C273.332 432.969 272.467 433.722 271.667 434.522C270.862 435.324 270.109 436.191 269.426 437.102C268.747 438.006 268.123 438.972 267.571 439.971C267.038 440.936 266.568 441.949 266.171 442.985L257.542 472.206Z" fill="#EFDB5D"/>
<mask id="path-15-outside-1_62_3" maskUnits="userSpaceOnUse" x="385.298" y="388.442" width="453" height="371" fill="black">
<rect fill="white" x="385.298" y="388.442" width="453" height="371"/>
<path d="M830.355 552.774H818.102L776.34 421.449C782.017 417.127 784.555 409.508 781.992 402.46C780.462 398.258 777.393 394.905 773.34 393.018C769.287 391.131 764.747 390.932 760.545 392.457C756.343 393.987 752.99 397.056 751.098 401.114C749.935 403.607 749.493 406.285 749.622 408.957L641.115 448.315C635.358 437.825 624.207 430.692 611.418 430.692C592.752 430.692 577.568 445.881 577.568 464.542C577.568 466.822 577.801 469.042 578.233 471.198L469.82 510.789C468.201 508.663 466.14 506.895 463.651 505.733C459.603 503.85 455.053 503.642 450.851 505.176C442.179 508.33 437.694 517.956 440.848 526.629C442.035 529.887 444.151 532.539 446.774 534.432L405.518 664.158H393.265C390.523 664.158 388.298 666.378 388.298 669.125V685.938C388.298 699.11 399.017 709.834 412.194 709.834H500.948C514.12 709.834 524.844 699.115 524.844 685.938V669.125C524.844 666.378 522.619 664.158 519.877 664.158H507.624L466.363 534.397C468.643 532.748 470.521 530.597 471.742 527.98C472.905 525.481 473.347 522.804 473.218 520.127L581.601 480.545C584.636 486.178 589.225 490.842 594.783 493.991V664.506C565.642 666.388 542.387 689.986 541.036 719.266H526.105C523.364 719.266 521.139 721.486 521.139 724.233V751.333C521.139 754.079 523.364 756.3 526.105 756.3H696.74C699.486 756.3 701.706 754.079 701.706 751.333V724.233C701.706 721.486 699.486 719.266 696.74 719.266H681.804C680.453 689.981 657.198 666.383 628.057 664.506V493.991C638.323 488.17 645.277 477.158 645.277 464.537C645.277 462.168 645.029 459.858 644.562 457.623L753.02 418.29C754.242 419.899 755.737 421.265 757.48 422.343L716.001 552.774H703.748C701.001 552.774 698.781 555 698.781 557.741V574.554C698.781 587.727 709.5 598.445 722.677 598.445H811.431C824.603 598.445 835.327 587.727 835.327 574.554V557.741C835.322 555 833.102 552.774 830.355 552.774ZM454.244 514.514C455.004 514.236 455.794 514.102 456.573 514.102C457.557 514.102 458.53 514.315 459.449 514.743C461.098 515.508 462.345 516.873 462.966 518.577V518.582C463.582 520.286 463.507 522.133 462.737 523.778C461.972 525.427 460.607 526.673 458.903 527.294C455.386 528.59 451.462 526.753 450.181 523.231C448.894 519.71 450.722 515.796 454.244 514.514ZM514.91 685.933C514.91 693.632 508.647 699.895 500.948 699.895H412.194C404.495 699.895 398.232 693.632 398.232 685.933V674.087H514.91V685.933ZM415.944 664.158L456.186 537.615C456.325 537.62 456.459 537.645 456.593 537.645C456.712 537.645 456.837 537.615 456.961 537.615L497.198 664.158H415.944ZM691.773 746.371H531.072V729.205H545.869H676.976H691.773V746.371ZM671.935 719.271H550.905C552.296 694.213 573.117 674.256 598.513 674.256H599.75H623.085H624.322C649.723 674.256 670.539 694.213 671.935 719.271ZM618.123 664.322H604.722V497.726C606.888 498.163 609.128 498.396 611.423 498.396C613.717 498.396 615.957 498.163 618.123 497.726V664.322ZM611.423 488.468C598.235 488.468 587.507 477.734 587.507 464.547C587.507 451.36 598.235 440.631 611.423 440.631C624.615 440.631 635.343 451.36 635.343 464.547C635.343 477.734 624.61 488.468 611.423 488.468ZM760.103 405.306C760.873 403.662 762.239 402.41 763.942 401.79C764.702 401.511 765.492 401.377 766.277 401.377C767.255 401.377 768.234 401.591 769.148 402.018C770.792 402.788 772.043 404.149 772.664 405.853C773.946 409.379 772.123 413.293 768.601 414.574C766.893 415.2 765.05 415.116 763.396 414.351C761.757 413.586 760.505 412.225 759.884 410.517C759.884 410.512 759.879 410.512 759.879 410.507C759.258 408.803 759.333 406.955 760.103 405.306ZM767.051 425.02L807.676 552.774H726.427L767.051 425.02ZM825.388 574.554C825.388 582.253 819.125 588.517 811.426 588.517H722.677C714.978 588.517 708.715 582.253 708.715 574.554V562.708H719.617C719.622 562.708 719.627 562.708 719.632 562.708C719.637 562.708 719.642 562.708 719.647 562.708H814.456C814.461 562.708 814.466 562.708 814.471 562.708C814.476 562.708 814.481 562.708 814.486 562.708H825.388V574.554Z"/>
</mask>
<path d="M830.355 552.774H818.102L776.34 421.449C782.017 417.127 784.555 409.508 781.992 402.46C780.462 398.258 777.393 394.905 773.34 393.018C769.287 391.131 764.747 390.932 760.545 392.457C756.343 393.987 752.99 397.056 751.098 401.114C749.935 403.607 749.493 406.285 749.622 408.957L641.115 448.315C635.358 437.825 624.207 430.692 611.418 430.692C592.752 430.692 577.568 445.881 577.568 464.542C577.568 466.822 577.801 469.042 578.233 471.198L469.82 510.789C468.201 508.663 466.14 506.895 463.651 505.733C459.603 503.85 455.053 503.642 450.851 505.176C442.179 508.33 437.694 517.956 440.848 526.629C442.035 529.887 444.151 532.539 446.774 534.432L405.518 664.158H393.265C390.523 664.158 388.298 666.378 388.298 669.125V685.938C388.298 699.11 399.017 709.834 412.194 709.834H500.948C514.12 709.834 524.844 699.115 524.844 685.938V669.125C524.844 666.378 522.619 664.158 519.877 664.158H507.624L466.363 534.397C468.643 532.748 470.521 530.597 471.742 527.98C472.905 525.481 473.347 522.804 473.218 520.127L581.601 480.545C584.636 486.178 589.225 490.842 594.783 493.991V664.506C565.642 666.388 542.387 689.986 541.036 719.266H526.105C523.364 719.266 521.139 721.486 521.139 724.233V751.333C521.139 754.079 523.364 756.3 526.105 756.3H696.74C699.486 756.3 701.706 754.079 701.706 751.333V724.233C701.706 721.486 699.486 719.266 696.74 719.266H681.804C680.453 689.981 657.198 666.383 628.057 664.506V493.991C638.323 488.17 645.277 477.158 645.277 464.537C645.277 462.168 645.029 459.858 644.562 457.623L753.02 418.29C754.242 419.899 755.737 421.265 757.48 422.343L716.001 552.774H703.748C701.001 552.774 698.781 555 698.781 557.741V574.554C698.781 587.727 709.5 598.445 722.677 598.445H811.431C824.603 598.445 835.327 587.727 835.327 574.554V557.741C835.322 555 833.102 552.774 830.355 552.774ZM454.244 514.514C455.004 514.236 455.794 514.102 456.573 514.102C457.557 514.102 458.53 514.315 459.449 514.743C461.098 515.508 462.345 516.873 462.966 518.577V518.582C463.582 520.286 463.507 522.133 462.737 523.778C461.972 525.427 460.607 526.673 458.903 527.294C455.386 528.59 451.462 526.753 450.181 523.231C448.894 519.71 450.722 515.796 454.244 514.514ZM514.91 685.933C514.91 693.632 508.647 699.895 500.948 699.895H412.194C404.495 699.895 398.232 693.632 398.232 685.933V674.087H514.91V685.933ZM415.944 664.158L456.186 537.615C456.325 537.62 456.459 537.645 456.593 537.645C456.712 537.645 456.837 537.615 456.961 537.615L497.198 664.158H415.944ZM691.773 746.371H531.072V729.205H545.869H676.976H691.773V746.371ZM671.935 719.271H550.905C552.296 694.213 573.117 674.256 598.513 674.256H599.75H623.085H624.322C649.723 674.256 670.539 694.213 671.935 719.271ZM618.123 664.322H604.722V497.726C606.888 498.163 609.128 498.396 611.423 498.396C613.717 498.396 615.957 498.163 618.123 497.726V664.322ZM611.423 488.468C598.235 488.468 587.507 477.734 587.507 464.547C587.507 451.36 598.235 440.631 611.423 440.631C624.615 440.631 635.343 451.36 635.343 464.547C635.343 477.734 624.61 488.468 611.423 488.468ZM760.103 405.306C760.873 403.662 762.239 402.41 763.942 401.79C764.702 401.511 765.492 401.377 766.277 401.377C767.255 401.377 768.234 401.591 769.148 402.018C770.792 402.788 772.043 404.149 772.664 405.853C773.946 409.379 772.123 413.293 768.601 414.574C766.893 415.2 765.05 415.116 763.396 414.351C761.757 413.586 760.505 412.225 759.884 410.517C759.884 410.512 759.879 410.512 759.879 410.507C759.258 408.803 759.333 406.955 760.103 405.306ZM767.051 425.02L807.676 552.774H726.427L767.051 425.02ZM825.388 574.554C825.388 582.253 819.125 588.517 811.426 588.517H722.677C714.978 588.517 708.715 582.253 708.715 574.554V562.708H719.617C719.622 562.708 719.627 562.708 719.632 562.708C719.637 562.708 719.642 562.708 719.647 562.708H814.456C814.461 562.708 814.466 562.708 814.471 562.708C814.476 562.708 814.481 562.708 814.486 562.708H825.388V574.554Z" fill="black"/>
<path d="M830.355 552.774H818.102L776.34 421.449C782.017 417.127 784.555 409.508 781.992 402.46C780.462 398.258 777.393 394.905 773.34 393.018C769.287 391.131 764.747 390.932 760.545 392.457C756.343 393.987 752.99 397.056 751.098 401.114C749.935 403.607 749.493 406.285 749.622 408.957L641.115 448.315C635.358 437.825 624.207 430.692 611.418 430.692C592.752 430.692 577.568 445.881 577.568 464.542C577.568 466.822 577.801 469.042 578.233 471.198L469.82 510.789C468.201 508.663 466.14 506.895 463.651 505.733C459.603 503.85 455.053 503.642 450.851 505.176C442.179 508.33 437.694 517.956 440.848 526.629C442.035 529.887 444.151 532.539 446.774 534.432L405.518 664.158H393.265C390.523 664.158 388.298 666.378 388.298 669.125V685.938C388.298 699.11 399.017 709.834 412.194 709.834H500.948C514.12 709.834 524.844 699.115 524.844 685.938V669.125C524.844 666.378 522.619 664.158 519.877 664.158H507.624L466.363 534.397C468.643 532.748 470.521 530.597 471.742 527.98C472.905 525.481 473.347 522.804 473.218 520.127L581.601 480.545C584.636 486.178 589.225 490.842 594.783 493.991V664.506C565.642 666.388 542.387 689.986 541.036 719.266H526.105C523.364 719.266 521.139 721.486 521.139 724.233V751.333C521.139 754.079 523.364 756.3 526.105 756.3H696.74C699.486 756.3 701.706 754.079 701.706 751.333V724.233C701.706 721.486 699.486 719.266 696.74 719.266H681.804C680.453 689.981 657.198 666.383 628.057 664.506V493.991C638.323 488.17 645.277 477.158 645.277 464.537C645.277 462.168 645.029 459.858 644.562 457.623L753.02 418.29C754.242 419.899 755.737 421.265 757.48 422.343L716.001 552.774H703.748C701.001 552.774 698.781 555 698.781 557.741V574.554C698.781 587.727 709.5 598.445 722.677 598.445H811.431C824.603 598.445 835.327 587.727 835.327 574.554V557.741C835.322 555 833.102 552.774 830.355 552.774ZM454.244 514.514C455.004 514.236 455.794 514.102 456.573 514.102C457.557 514.102 458.53 514.315 459.449 514.743C461.098 515.508 462.345 516.873 462.966 518.577V518.582C463.582 520.286 463.507 522.133 462.737 523.778C461.972 525.427 460.607 526.673 458.903 527.294C455.386 528.59 451.462 526.753 450.181 523.231C448.894 519.71 450.722 515.796 454.244 514.514ZM514.91 685.933C514.91 693.632 508.647 699.895 500.948 699.895H412.194C404.495 699.895 398.232 693.632 398.232 685.933V674.087H514.91V685.933ZM415.944 664.158L456.186 537.615C456.325 537.62 456.459 537.645 456.593 537.645C456.712 537.645 456.837 537.615 456.961 537.615L497.198 664.158H415.944ZM691.773 746.371H531.072V729.205H545.869H676.976H691.773V746.371ZM671.935 719.271H550.905C552.296 694.213 573.117 674.256 598.513 674.256H599.75H623.085H624.322C649.723 674.256 670.539 694.213 671.935 719.271ZM618.123 664.322H604.722V497.726C606.888 498.163 609.128 498.396 611.423 498.396C613.717 498.396 615.957 498.163 618.123 497.726V664.322ZM611.423 488.468C598.235 488.468 587.507 477.734 587.507 464.547C587.507 451.36 598.235 440.631 611.423 440.631C624.615 440.631 635.343 451.36 635.343 464.547C635.343 477.734 624.61 488.468 611.423 488.468ZM760.103 405.306C760.873 403.662 762.239 402.41 763.942 401.79C764.702 401.511 765.492 401.377 766.277 401.377C767.255 401.377 768.234 401.591 769.148 402.018C770.792 402.788 772.043 404.149 772.664 405.853C773.946 409.379 772.123 413.293 768.601 414.574C766.893 415.2 765.05 415.116 763.396 414.351C761.757 413.586 760.505 412.225 759.884 410.517C759.884 410.512 759.879 410.512 759.879 410.507C759.258 408.803 759.333 406.955 760.103 405.306ZM767.051 425.02L807.676 552.774H726.427L767.051 425.02ZM825.388 574.554C825.388 582.253 819.125 588.517 811.426 588.517H722.677C714.978 588.517 708.715 582.253 708.715 574.554V562.708H719.617C719.622 562.708 719.627 562.708 719.632 562.708C719.637 562.708 719.642 562.708 719.647 562.708H814.456C814.461 562.708 814.466 562.708 814.471 562.708C814.476 562.708 814.481 562.708 814.486 562.708H825.388V574.554Z" stroke="black" stroke-width="5.65919" mask="url(#path-15-outside-1_62_3)"/>
</svg>

Before

Width:  |  Height:  |  Size: 18 KiB

@ -0,0 +1,112 @@
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
width="702.000000pt" height="565.000000pt" viewBox="0 0 702.000000 565.000000"
preserveAspectRatio="xMidYMid meet">
<g transform="translate(0.000000,565.000000) scale(0.100000,-0.100000)"
fill="#000000" stroke="none">
<path d="M0 2825 l0 -2825 3510 0 3510 0 0 2825 0 2825 -3510 0 -3510 0 0
-2825z m1705 2138 c-6 -38 -25 -53 -20 -17 2 16 4 35 4 42 1 7 6 10 11 7 6 -3
8 -18 5 -32z m3625 7 c0 -5 -2 -10 -4 -10 -3 0 -8 5 -11 10 -3 6 -1 10 4 10 6
0 11 -4 11 -10z m30 0 c0 -5 -2 -10 -4 -10 -3 0 -8 5 -11 10 -3 6 -1 10 4 10
6 0 11 -4 11 -10z m-3542 -76 c12 -15 22 -23 22 -17 0 7 -8 20 -19 30 -10 10
-21 29 -24 43 -5 22 -5 23 7 8 7 -10 21 -18 31 -18 26 0 72 -30 86 -57 7 -12
14 -21 16 -19 7 7 165 -146 963 -929 146 -143 286 -280 312 -305 l48 -44 36
42 c19 23 57 54 82 70 41 23 58 27 127 27 97 0 149 -23 212 -93 l42 -47 113
110 c62 60 246 240 408 400 162 159 387 379 500 488 113 108 231 222 262 253
36 36 61 53 69 48 9 -5 10 -2 6 9 -3 9 -3 16 1 16 24 -4 34 3 28 18 -4 10 -4
14 0 11 3 -4 13 -1 21 7 8 8 20 15 26 15 9 0 9 -2 1 -8 -21 -14 -35 -50 -22
-58 7 -4 8 -3 4 4 -6 10 17 18 27 10 1 -2 17 12 35 30 37 37 48 41 30 10 -7
-13 -11 -27 -10 -31 1 -5 -2 -6 -8 -2 -5 3 -10 -1 -10 -9 0 -9 -4 -15 -9 -13
-5 1 -10 -1 -11 -5 -3 -16 -67 -78 -80 -78 -7 0 -10 -3 -6 -7 4 -4 -196 -209
-445 -456 -341 -338 -451 -452 -443 -462 16 -23 1043 -945 1053 -945 5 0 11
382 14 953 5 849 8 1002 17 1002 1 0 4 10 5 22 2 15 -5 23 -21 27 -13 4 -24
11 -24 17 0 8 4 8 14 0 8 -6 20 -10 27 -9 8 2 15 -8 17 -22 l4 -24 13 23 c11
22 12 19 9 -30 -1 -30 0 -40 2 -24 2 17 7 41 10 55 5 24 6 24 17 5 9 -15 13
-299 15 -1107 l3 -1088 -565 0 c-311 0 -567 3 -569 8 -3 4 -8 28 -12 55 l-7
47 460 0 c254 0 463 4 466 9 5 8 -1013 941 -1036 950 -6 2 -93 -79 -193 -179
-163 -163 -183 -187 -188 -221 -3 -22 -17 -62 -32 -90 l-26 -51 23 -6 c13 -3
57 -23 99 -44 94 -47 178 -132 230 -233 69 -133 88 -224 99 -490 12 -274 27
-321 125 -372 125 -64 182 -149 192 -287 l6 -76 -983 0 -983 0 5 79 c8 132 62
217 177 276 105 53 126 110 136 370 4 99 8 196 8 215 l2 35 -632 3 -633 2 5
888 c6 960 11 1279 21 1307 6 15 8 15 20 -6 7 -13 18 -24 26 -24 7 -1 12 -7
10 -15 -1 -10 3 -9 13 4 14 18 14 18 14 -10 -5 -144 16 -1944 22 -1944 4 0 81
66 171 148 133 120 848 763 883 794 6 5 -154 172 -403 421 -227 227 -409 417
-405 422 4 4 3 5 -3 2 -10 -6 -147 128 -164 159 -3 5 -9 8 -13 6 -5 -1 -6 1
-4 6 3 4 -4 19 -15 32 -11 14 -17 19 -13 12 6 -11 3 -11 -14 0 -19 12 -19 13
-3 20 17 6 30 -4 80 -68z m-148 41 c0 -8 -4 -15 -10 -15 -5 0 -7 7 -4 15 4 8
8 15 10 15 2 0 4 -7 4 -15z m1750 -136 c0 -7 11 -8 33 -3 50 11 222 6 352 -10
165 -20 439 -156 614 -305 l35 -29 -42 -42 -43 -41 -48 40 c-398 333 -921 398
-1371 171 -83 -42 -202 -122 -258 -173 l-43 -41 -41 42 c-49 48 -50 46 59 128
181 136 454 256 568 249 20 -1 31 1 25 5 -7 4 21 8 61 9 40 1 75 4 78 6 8 9
21 5 21 -6z m350 -382 c79 -22 155 -53 229 -93 68 -38 181 -120 181 -133 0 -4
-17 -24 -39 -45 l-38 -38 -36 32 c-64 56 -198 129 -296 162 -92 31 -103 32
-256 33 -138 0 -171 -3 -239 -23 -97 -28 -220 -91 -303 -154 l-61 -47 -41 38
c-23 21 -41 41 -41 43 0 11 160 118 220 148 92 46 195 80 265 86 33 3 62 7 64
9 11 11 341 -5 391 -18z m-360 -348 c-11 -8 -9 -8 10 -3 23 8 144 10 200 4 76
-8 217 -67 275 -115 l30 -25 -41 -40 -40 -41 -52 35 c-97 65 -152 81 -287 81
-132 0 -175 -12 -280 -81 l-50 -33 -40 40 -40 40 30 25 c42 35 144 84 218 105
73 21 87 23 67 8z m-48 -2442 c92 -88 180 -96 269 -21 36 30 48 34 86 32 42
-2 44 -3 38 -27 -17 -68 -86 -134 -169 -161 -58 -19 -156 -8 -210 24 -68 40
-125 118 -112 153 7 17 80 17 98 0z m-1631 -812 c40 -26 79 -95 79 -140 0 -41
-37 -111 -71 -136 -46 -33 -88 -41 -142 -28 -95 22 -152 115 -127 205 32 115
161 163 261 99z m519 11 c14 -6 25 -18 25 -26 0 -10 -8 -14 -25 -12 -14 2 -44
6 -66 9 -77 9 -134 -43 -134 -122 0 -45 21 -87 54 -109 29 -19 94 -21 130 -5
20 9 29 9 41 -1 26 -22 -35 -54 -101 -54 -153 3 -227 180 -119 288 52 52 126
64 195 32z m268 -149 c2 -162 2 -167 -18 -167 -19 0 -20 6 -20 163 0 90 3 167
7 171 22 22 28 -11 31 -167z m742 23 l5 -145 78 -3 c69 -3 77 -5 77 -22 0 -19
-7 -20 -100 -20 l-100 0 0 171 c0 157 1 170 18 167 15 -3 18 -20 22 -148z
m886 134 c37 -18 41 -26 21 -42 -8 -7 -19 -6 -37 3 -61 34 -149 4 -176 -60
-18 -44 -18 -69 2 -110 21 -46 59 -69 116 -69 40 -1 52 4 82 33 20 19 36 43
36 53 0 15 -9 18 -60 18 -53 0 -60 2 -60 20 0 18 7 20 85 20 84 0 85 0 85 -25
0 -72 -69 -149 -144 -160 -138 -21 -240 120 -176 245 18 36 55 70 90 83 31 11
103 7 136 -9z m336 -110 c3 -125 3 -126 32 -151 23 -19 36 -23 60 -19 55 11
61 25 66 164 5 119 6 127 25 127 18 0 20 -8 23 -80 5 -123 -5 -179 -37 -214
-55 -59 -148 -48 -191 21 -17 28 -20 51 -20 156 0 114 1 122 19 122 18 0 20
-10 23 -126z m-3252 96 c0 -18 -7 -20 -54 -20 -61 0 -86 -16 -86 -55 0 -24 23
-55 41 -55 5 0 9 10 9 21 0 19 4 21 37 16 43 -7 90 -49 98 -87 9 -40 -18 -96
-54 -114 -18 -10 -56 -16 -96 -16 -58 0 -66 2 -63 18 3 13 17 18 69 22 77 6
99 20 99 64 0 37 -7 49 -37 65 -31 16 -40 14 -46 -9 -7 -27 -29 -25 -65 5 -38
32 -47 67 -27 109 20 42 46 54 118 55 51 1 57 -1 57 -19z m1715 -136 c39 -86
72 -161 73 -165 2 -5 -65 -9 -148 -9 -136 0 -151 2 -146 16 23 60 140 314 145
314 3 0 38 -70 76 -156z m2161 -1 l70 -158 -144 -3 c-80 -1 -146 -1 -149 1 -5
6 138 317 146 317 4 0 38 -71 77 -157z m467 137 c34 -27 44 -78 23 -119 -9
-17 -20 -31 -24 -31 -4 0 -13 -4 -21 -9 -11 -7 -7 -21 23 -74 20 -36 36 -68
36 -72 0 -3 -10 -5 -22 -3 -15 2 -34 24 -61 71 -38 66 -40 68 -76 65 l-36 -3
-3 -67 c-3 -60 -5 -68 -22 -68 -18 0 -20 7 -20 90 l0 90 74 0 c89 0 105 5 117
38 7 18 5 31 -6 48 -14 22 -22 24 -100 24 -78 0 -85 2 -85 20 0 18 7 20 89 20
74 0 93 -3 114 -20z m423 -5 c56 -33 89 -98 80 -158 -16 -97 -83 -147 -199
-147 l-67 0 0 165 0 165 72 0 c58 0 79 -5 114 -25z m-3798 -138 c4 -20 -25
-34 -40 -19 -15 15 -1 44 19 40 10 -2 19 -11 21 -21z m2388 -32 c8 -20 -13
-45 -32 -38 -14 5 -19 34 -7 46 11 12 33 7 39 -8z"/>
<path d="M1852 4910 c0 -14 2 -19 5 -12 2 6 2 18 0 25 -3 6 -5 1 -5 -13z"/>
<path d="M1875 4900 c-3 -5 -1 -10 4 -10 6 0 11 5 11 10 0 6 -2 10 -4 10 -3 0
-8 -4 -11 -10z"/>
<path d="M5340 4879 c0 -5 5 -7 10 -4 6 3 10 8 10 11 0 2 -4 4 -10 4 -5 0 -10
-5 -10 -11z"/>
<path d="M1860 4870 c0 -5 5 -10 11 -10 5 0 7 5 4 10 -3 6 -8 10 -11 10 -2 0
-4 -4 -4 -10z"/>
<path d="M2540 3524 c-657 -596 -720 -655 -720 -664 0 -6 220 -10 596 -10 564
0 596 -1 589 -17 -23 -60 -38 -183 -45 -368 -6 -178 -11 -218 -29 -266 -33
-86 -72 -133 -151 -180 -76 -45 -120 -89 -120 -120 0 -19 18 -19 850 -19 708
0 850 2 850 14 0 31 -48 83 -106 113 -78 42 -135 104 -164 179 -20 51 -24 87
-31 264 -4 113 -14 240 -23 282 -59 305 -229 448 -529 448 -167 0 -290 -46
-385 -142 -50 -52 -56 -55 -107 -57 -29 -1 -56 3 -60 8 -3 6 7 30 23 53 55 80
124 138 220 185 50 26 92 50 92 54 0 4 -9 23 -19 41 -11 18 -25 56 -31 83 -10
47 -23 62 -188 228 -97 97 -181 177 -187 177 -5 0 -152 -129 -325 -286z"/>
<path d="M3450 3609 c-123 -49 -136 -226 -21 -293 127 -74 283 61 230 201 -30
80 -129 123 -209 92z"/>
<path d="M1568 784 c-78 -42 -76 -178 2 -219 37 -19 93 -19 130 0 79 41 79
179 0 220 -37 19 -97 19 -132 -1z m90 -107 c4 -20 -25 -34 -40 -19 -15 15 -1
44 19 40 10 -2 19 -11 21 -21z"/>
<path d="M2851 708 c-5 -13 -21 -49 -35 -81 -14 -32 -26 -62 -26 -67 0 -6 35
-10 80 -10 44 0 80 4 80 9 0 18 -73 171 -82 171 -5 0 -12 -10 -17 -22z"/>
<path d="M4987 658 c-21 -46 -37 -86 -37 -90 0 -5 36 -8 80 -8 44 0 80 2 80 4
0 8 -79 176 -83 176 -2 0 -20 -37 -40 -82z"/>
<path d="M5860 675 l0 -125 35 0 c82 0 135 49 135 125 0 76 -51 125 -130 125
l-40 0 0 -125z m103 13 c7 -21 -4 -38 -23 -38 -23 0 -34 16 -26 35 7 18 43 20
49 3z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 7.4 KiB

@ -1,16 +1,15 @@
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="Justice.Views.MapTimer"
Title="Track Journey">
Title="Journey Tracker">
<VerticalStackLayout Padding="20" Spacing="15">
<!-- Page Title -->
<Label Text="Track Your Journey" FontSize="Large" HorizontalOptions="Center" FontAttributes="Bold" />
<Label Text="Destination Tracker" FontSize="Large" HorizontalOptions="Center" FontAttributes="Bold" />
<!-- Current Location -->
<Label Text="Current Location (Latitude, Longitude):" FontSize="Medium" />
<Entry x:Name="SourceLatitudeEntry" IsReadOnly="True" Placeholder="Latitude" />
<Entry x:Name="SourceLongitudeEntry" IsReadOnly="True" Placeholder="Longitude" />
<Entry x:Name="SourceAddressEntry" IsReadOnly="True" Placeholder="Address" />
<!-- Destination Location -->
<Label Text="Destination Location (Latitude, Longitude):" FontSize="Medium" />
@ -18,8 +17,8 @@
<Entry x:Name="DestinationLongitudeEntry" Placeholder="Enter Destination Longitude" />
<!-- Timer -->
<Label Text="Set Timer (minutes):" FontSize="Medium" />
<Entry x:Name="TimerEntry" Keyboard="Numeric" Placeholder="Enter timer in minutes" />
<Label Text="Set Timer (seconds):" FontSize="Medium" />
<Entry x:Name="TimerEntry" Keyboard="Numeric" Placeholder="Enter timer in seconds" />
<!-- Countdown Display -->
<Label x:Name="TimerLabel"

@ -1,14 +1,16 @@
using Justice.Helpers;
using Microsoft.Maui.ApplicationModel.Communication;
using System;
using System.Collections.Generic;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.Maui.ApplicationModel.Communication;
namespace Justice.Views
{
public partial class MapTimer : ContentPage
{
private bool isTrackingActive;
private CancellationTokenSource _cancellationTokenSource;
private readonly double _tolerance = 0.0001;
public MapTimer()
{
@ -16,126 +18,126 @@ namespace Justice.Views
FetchLocation();
}
private async void StartTrackingClicked(object sender, EventArgs e)
private async void FetchLocation()
{
if (string.IsNullOrWhiteSpace(DestinationLatitudeEntry.Text) ||
string.IsNullOrWhiteSpace(DestinationLongitudeEntry.Text))
try
{
await DisplayAlert("Error", "Please enter destination coordinates.", "OK");
return;
var (latitude, longitude, address) = await GeolocationHelper.GetLocationAsync();
SourceLatitudeEntry.Text = latitude.ToString();
SourceLongitudeEntry.Text = longitude.ToString();
}
catch (Exception ex)
{
await DisplayAlert("Error", $"Failed to fetch location: {ex.Message}", "OK");
}
}
private async void StartTrackingClicked(object sender, EventArgs e)
{
if (!double.TryParse(DestinationLatitudeEntry.Text, out double destinationLatitude) ||
!double.TryParse(DestinationLongitudeEntry.Text, out double destinationLongitude))
{
await DisplayAlert("Error", "Invalid destination coordinates.", "OK");
await DisplayAlert("Error", "Please enter valid destination coordinates.", "OK");
return;
}
if (!int.TryParse(TimerEntry.Text, out int timerMinutes))
if (!int.TryParse(TimerEntry.Text, out int timerSeconds) || timerSeconds <= 0)
{
await DisplayAlert("Error", "Invalid timer value. Please enter a numeric value.", "OK");
await DisplayAlert("Error", "Please enter a valid timer value in seconds.", "OK");
return;
}
isTrackingActive = true;
// Set timer duration
var timerDuration = TimeSpan.FromMinutes(timerMinutes);
var timerEnd = DateTime.Now.Add(timerDuration);
string phoneNumber = "9860104625";
await StartTimerAsync(destinationLatitude, destinationLongitude, timerSeconds);
}
// Start countdown display
_ = UpdateCountdownDisplay(timerEnd);
private async Task StartTimerAsync(double destinationLatitude, double destinationLongitude, int timerSeconds)
{
var startTime = DateTime.Now;
var endTime = startTime.AddSeconds(timerSeconds);
_cancellationTokenSource = new CancellationTokenSource();
while (isTrackingActive && DateTime.Now < timerEnd)
while (DateTime.Now <= endTime)
{
await Task.Delay(5000); // Check location every 5 seconds
if (_cancellationTokenSource.Token.IsCancellationRequested)
return;
// Fetch current location
// Fetch the current location
var (currentLatitude, currentLongitude, _) = await GeolocationHelper.GetLocationAsync();
// Define tolerance for proximity
const double Tolerance = 0.0001;
// Update TimerLabel
var remainingTime = endTime - DateTime.Now;
TimerLabel.Text = $"Remaining Time: {remainingTime.Seconds}s";
// Check if user has reached the destination
if (Math.Abs(destinationLatitude - currentLatitude) < Tolerance &&
Math.Abs(destinationLongitude - currentLongitude) < Tolerance)
// Check if the user has reached the destination
if (Math.Abs(destinationLatitude - currentLatitude) < _tolerance &&
Math.Abs(destinationLongitude - currentLongitude) < _tolerance)
{
isTrackingActive = false;
// Notify user and send SMS
string reachedMessage = "User has safely reached the destination.";
await DisplayAlert("Success", "Safely reached the destination!", "OK");
await SendSmsNotification(phoneNumber, reachedMessage);
var successMessage = "Safely reached the destination!";
await SendSmsNotification("9767581384", successMessage);
//await SendEmailNotification("amreitsyanf@gmail.com", "Journey Update", successMessage);
TimerLabel.Text = "Journey Complete.";
return;
}
}
// If timer expires and destination is not reached
if (isTrackingActive)
{
string notReachedMessage = "User did not reach the destination within the set time.";
await DisplayAlert("Time's Up", "You did not reach the destination within the set timer.", "OK");
await SendSmsNotification(phoneNumber, notReachedMessage);
}
}
private async Task UpdateCountdownDisplay(DateTime timerEnd)
{
while (isTrackingActive && DateTime.Now < timerEnd)
{
TimeSpan remainingTime = timerEnd - DateTime.Now;
// Update the UI with remaining time
TimerLabel.Text = $"Time Remaining: {remainingTime.Minutes:D2}:{remainingTime.Seconds:D2}";
// Wait for 1 second before updating again
// Wait for 1 second before re-checking
await Task.Delay(1000);
}
// Clear the timer label after countdown ends
TimerLabel.Text = isTrackingActive ? "Time's Up!" : "You reached the destination!";
// Timer expired, user didn't reach the destination
var failureMessage = "Did not reach the destination on time.";
await SendSmsNotification("9767581384", failureMessage);
//await SendEmailNotification("amreitsyanf@gmail.com", "Journey Update", failureMessage);
//await DisplayAlert("Alert", failureMessage, "OK");
TimerLabel.Text = "Time Expired.";
}
private async void FetchLocation()
private async Task SendSmsNotification(string phoneNumber, string message)
{
try
{
var (latitude, longitude, address) = await GeolocationHelper.GetLocationAsync();
SourceLatitudeEntry.Text = latitude.ToString();
SourceLongitudeEntry.Text = longitude.ToString();
if (Sms.Default.IsComposeSupported)
{
var smsMessage = new SmsMessage
{
Body = message,
Recipients = new List<string> { phoneNumber }
};
await Sms.Default.ComposeAsync(smsMessage);
}
else
{
await DisplayAlert("Error", "SMS is not supported on this device.", "OK");
}
}
catch (Exception ex)
{
Console.WriteLine($"Error fetching location: {ex.Message}");
await DisplayAlert("Error", $"Failed to get location: {ex.Message}", "OK");
await DisplayAlert("Error", $"Failed to send SMS: {ex.Message}", "OK");
}
}
private async Task SendSmsNotification(string phoneNumber, string message)
private async Task SendEmailNotification(string emailAddress, string subject, string body)
{
try
{
if (Sms.Default.IsComposeSupported)
if (Email.Default.IsComposeSupported)
{
var smsMessage = new SmsMessage
var emailMessage = new EmailMessage
{
Body = message,
Recipients = new List<string> { phoneNumber }
Subject = subject,
Body = body,
To = new List<string> { emailAddress }
};
await Sms.Default.ComposeAsync(smsMessage);
await Email.Default.ComposeAsync(emailMessage);
}
else
{
await DisplayAlert("Error", "SMS is not supported on this device.", "OK");
await DisplayAlert("Error", "Email is not supported on this device.", "OK");
}
}
catch (Exception ex)
{
Console.WriteLine($"Error sending SMS: {ex.Message}");
await DisplayAlert("Error", "Failed to send SMS.", "OK");
await DisplayAlert("Error", $"Failed to send email: {ex.Message}", "OK");
}
}
}

Loading…
Cancel
Save