diff --git a/GUT.Schedule/GUT.Schedule.sln b/GUT.Schedule/GUT.Schedule.sln index 4281a71..89fccf2 100644 --- a/GUT.Schedule/GUT.Schedule.sln +++ b/GUT.Schedule/GUT.Schedule.sln @@ -15,9 +15,9 @@ Global {A0471165-37F5-4309-8A92-42F1A6589EEE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {A0471165-37F5-4309-8A92-42F1A6589EEE}.Debug|Any CPU.Build.0 = Debug|Any CPU {A0471165-37F5-4309-8A92-42F1A6589EEE}.Debug|Any CPU.Deploy.0 = Debug|Any CPU - {A0471165-37F5-4309-8A92-42F1A6589EEE}.Release (APK)|Any CPU.ActiveCfg = Release|Any CPU - {A0471165-37F5-4309-8A92-42F1A6589EEE}.Release (APK)|Any CPU.Build.0 = Release|Any CPU - {A0471165-37F5-4309-8A92-42F1A6589EEE}.Release (APK)|Any CPU.Deploy.0 = Release|Any CPU + {A0471165-37F5-4309-8A92-42F1A6589EEE}.Release (APK)|Any CPU.ActiveCfg = Release (APK)|Any CPU + {A0471165-37F5-4309-8A92-42F1A6589EEE}.Release (APK)|Any CPU.Build.0 = Release (APK)|Any CPU + {A0471165-37F5-4309-8A92-42F1A6589EEE}.Release (APK)|Any CPU.Deploy.0 = Release (APK)|Any CPU {A0471165-37F5-4309-8A92-42F1A6589EEE}.Release|Any CPU.ActiveCfg = Release|Any CPU {A0471165-37F5-4309-8A92-42F1A6589EEE}.Release|Any CPU.Build.0 = Release|Any CPU {A0471165-37F5-4309-8A92-42F1A6589EEE}.Release|Any CPU.Deploy.0 = Release|Any CPU diff --git a/GUT.Schedule/GUT.Schedule/Activities/AboutActivity.cs b/GUT.Schedule/GUT.Schedule/Activities/AboutActivity.cs new file mode 100644 index 0000000..f3a8f6f --- /dev/null +++ b/GUT.Schedule/GUT.Schedule/Activities/AboutActivity.cs @@ -0,0 +1,86 @@ +using Android.App; +using Android.Content; +using Android.Content.PM; +using Android.OS; +using Android.Support.V4.Text; +using Android.Support.V7.App; +using Android.Text.Method; +using Android.Widget; +using Newtonsoft.Json; +using System.Collections.Generic; +using System.Linq; +using System.Net.Http; + +namespace GUT.Schedule.Activities +{ + [Activity(Label = "@string/aboutTitle")] + public class AboutActivity : AppCompatActivity + { + protected override async void OnCreate(Bundle savedInstanceState) + { + (string name, string handle, string link)[] contacts = new (string, string, string)[] + { + (Resources.GetText(Resource.String.websiteContact), "https://xfox111.net", "https://xfox111.net"), + (Resources.GetText(Resource.String.twitterContact), "@xfox111", "https://twitter.com/xfox111"), + (Resources.GetText(Resource.String.vkontakteContact), "@xfox.mike", "https://vk.com/xfox.mike"), + ("LinkedIn", "@xfox", "https://linkedin.com/in/xfox"), + ("GitHub", "@xfox111", "https://github.com/xfox111"), + }; + (string name, string link)[] links = new (string, string)[] + { + (Resources.GetText(Resource.String.privacyPolicyLink), "https://xfox111.net/Projects/GUTSchedule/PrivacyPolicy.txt"), + ("General Public License v3", "https://www.gnu.org/licenses/gpl-3.0"), + (Resources.GetText(Resource.String.repositoryLink), "https://github.com/xfox111/gutschedule"), + (Resources.GetText(Resource.String.notsLink), "http://tios.spbgut.ru/index.php"), + (Resources.GetText(Resource.String.sutLink), "https://sut.ru"), + }; + + base.OnCreate(savedInstanceState); + SetContentView(Resource.Layout.About); + PackageInfo version = PackageManager.GetPackageInfo(PackageName, PackageInfoFlags.MatchAll); + FindViewById(Resource.Id.version).Text = $"v{version.VersionName} (ci-id #{version.VersionCode})"; + + FindViewById