Merge pull request 'POS_Sprint_7' (#9) from POS_Sprint_7 into develop
Reviewed-on: #9
This commit is contained in:
commit
4b41abf79d
@ -223,8 +223,6 @@ namespace Klient.Droid
|
||||
public void LoadFromCamera(View v)
|
||||
{
|
||||
Intent intent = new Intent(MediaStore.ActionImageCapture);
|
||||
//Android.Net.Uri pictureUri = Android.Net.Uri.FromFile(new File(GetExternalFilesDir(Android.OS.Environment.DirectoryDcim), Guid.NewGuid().ToString().Replace(".", "")+".jpg"));
|
||||
//intent.PutExtra(MediaStore.ExtraOutput, pictureUri);
|
||||
StartActivityForResult(intent, 0);
|
||||
|
||||
}
|
||||
@ -249,7 +247,9 @@ namespace Klient.Droid
|
||||
{
|
||||
photo = data;
|
||||
base.OnActivityResult(requestCode, resultCode, data);
|
||||
if(data != null) bitmap = (Bitmap)data.Extras.Get("data");
|
||||
if (data != null)
|
||||
{
|
||||
bitmap = (Bitmap)data.Extras.Get("data");
|
||||
|
||||
byte[] bitmapData;
|
||||
var stream = new MemoryStream();
|
||||
@ -259,14 +259,20 @@ namespace Klient.Droid
|
||||
|
||||
|
||||
FindViewById<ImageView>(Resource.Id.Preview).SetImageBitmap(bitmap);
|
||||
}
|
||||
else SetContentView(Resource.Layout.ekranPoLogowaniu);
|
||||
|
||||
}
|
||||
else if(requestCode == PickImageId)
|
||||
{
|
||||
if(data == null) SetContentView(Resource.Layout.ekranPoLogowaniu);
|
||||
else
|
||||
{
|
||||
Android.Net.Uri uri = data.Data;
|
||||
photo = data;
|
||||
FindViewById<ImageView>(Resource.Id.Preview).SetImageURI(uri);
|
||||
}
|
||||
}
|
||||
else if(data == null)
|
||||
{
|
||||
SetContentView(Resource.Layout.ekranPoLogowaniu);
|
||||
@ -308,7 +314,7 @@ namespace Klient.Droid
|
||||
if (fullLink.Count < 10) end = fullLink.Count;
|
||||
for (int i = 0; i < end; i++)
|
||||
{
|
||||
FindViewById<TextView>(Resource.Id.links).Text = FindViewById<TextView>(Resource.Id.links).Text + fullLink[i].title + ": " + fullLink[i].link + "\n\n";
|
||||
FindViewById<TextView>(Resource.Id.links).Text = FindViewById<TextView>(Resource.Id.links).Text + fullLink[i].title + ": \n" + fullLink[i].link + "\n\n";
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -459,5 +465,12 @@ namespace Klient.Droid
|
||||
{
|
||||
SetContentView(Resource.Layout.ekranPomocZdjecie);
|
||||
}
|
||||
|
||||
[Java.Interop.Export("LogOut")]
|
||||
public void LogOut(View v)
|
||||
{
|
||||
SetContentView(Resource.Layout.ekranStartowy);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
@ -181,6 +181,9 @@
|
||||
<ItemGroup>
|
||||
<AndroidResource Include="Resources\xml\file_paths.xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<AndroidResource Include="Resources\drawable\Obraz8.png" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildExtensionsPath)\Xamarin\Android\Xamarin.Android.CSharp.targets" />
|
||||
<ProjectExtensions>
|
||||
<VisualStudio>
|
||||
|
1184
Klient/Klient/Klient.Android/Resources/Resource.designer.cs
generated
1184
Klient/Klient/Klient.Android/Resources/Resource.designer.cs
generated
File diff suppressed because it is too large
Load Diff
BIN
Klient/Klient/Klient.Android/Resources/drawable/Obraz8.png
Normal file
BIN
Klient/Klient/Klient.Android/Resources/drawable/Obraz8.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 730 B |
@ -16,7 +16,7 @@
|
||||
android:layout_alignParentLeft="true"
|
||||
android:background="#ffbdd7f0"
|
||||
android:gravity="center"
|
||||
android:onClick="GoToProfile" />
|
||||
android:onClick="GoToPoLogowaniu" />
|
||||
<TextView
|
||||
android:text="Poszukiwacz 2021"
|
||||
android:textAppearance="?android:attr/textAppearanceSmall"
|
||||
|
@ -45,15 +45,14 @@
|
||||
android:textColor="#ff000000"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_centerHorizontal="true" />
|
||||
<Button
|
||||
android:text="Back"
|
||||
<ImageButton
|
||||
android:src="@drawable/obraz4"
|
||||
android:layout_width="38.5dp"
|
||||
android:layout_height="35.0dp"
|
||||
android:id="@+id/backRegisterHelp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:background="#ff0b31c8"
|
||||
android:textColor="#fffcfcfc"
|
||||
android:background="#ffbdd7f0"
|
||||
android:gravity="center"
|
||||
android:onClick="GoToRegister" />
|
||||
|
||||
|
@ -26,7 +26,7 @@
|
||||
android:gravity="center"
|
||||
android:onClick="GoToPoLogowaniu" />
|
||||
<TextView
|
||||
android:text="W celu załadowania zdjęcia z pamięci telefonu \nwybierz ikonę folderu, w celu zrobnienia zdjęcia \nwybierz ikonę aparatu i postępuj jak przy robieniu zdjęcia. \nNa następnym ekranie zostanie wyświtlony \npodgląd załadowanego zdjęcia."
|
||||
android:text="W celu załadowania zdjęcia z pamięci telefonu \nwybierz ikonę folderu, w celu zrobienia zdjęcia \nwybierz ikonę aparatu i postępuj jak przy robieniu zdjęcia. \nNa następnym ekranie zostanie wyświtlony \npodgląd załadowanego zdjęcia."
|
||||
android:textAppearance="?android:attr/textAppearanceMedium"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
|
@ -120,4 +120,13 @@
|
||||
android:layout_below="@id/Save"
|
||||
android:translationY="45dp"
|
||||
android:onClick="GetHistory" />
|
||||
<ImageButton
|
||||
android:src="@drawable/obraz8"
|
||||
android:layout_width="35.0dp"
|
||||
android:layout_height="35.0dp"
|
||||
android:background="#ffbdd7f0"
|
||||
android:id="@+id/LogOut"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:onClick="LogOut" />
|
||||
</RelativeLayout>
|
||||
|
@ -32,7 +32,7 @@ namespace Serwer.Api.Framework
|
||||
{
|
||||
var statusCode = HttpStatusCode.BadRequest;
|
||||
context.Response.StatusCode = (int)statusCode;
|
||||
return context.Response.WriteAsync($"Error: {exception.Message}");
|
||||
return context.Response.WriteAsync($"Błąd: {exception.Message}");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user