Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add double down enhancment #7

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions gen/com/swap/blackjack/BuildConfig.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
/** Automatically generated file. DO NOT MODIFY */
/*___Generated_by_IDEA___*/

package com.swap.blackjack;

/* This stub is only used by the IDE. It is NOT the BuildConfig class actually packed into the APK */
public final class BuildConfig {
public final static boolean DEBUG = true;
public final static boolean DEBUG = Boolean.parseBoolean(null);
}
254 changes: 245 additions & 9 deletions res/layout/activity_main.xml
Original file line number Diff line number Diff line change
@@ -1,19 +1,54 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/parentLayout"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/back11"
android:orientation="vertical" >
android:id="@+id/parentLayout"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/back11"
android:orientation="vertical">

<ScrollView
android:layout_width="fill_parent"
android:layout_height="wrap_content">

<ScrollView
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content" >
android:layout_height="wrap_content"
android:orientation="vertical">

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">

<ImageView
android:id="@+id/imgChips"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/chips"/>

<TextView
android:id="@+id/tvMoney"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="0"
android:textColor="#ffff00"
android:textSize="25sp"/>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical" >
android:layout_gravity="right"
android:gravity="right">

<TextView
android:id="@+id/tvHighest"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="right"
android:gravity="right"
android:text="0"
android:textAppearance="?android:attr/textAppearanceSmall"
android:textColor="#ffff00"/>

<LinearLayout
android:layout_width="fill_parent"
Expand Down Expand Up @@ -289,6 +324,207 @@
android:layout_marginLeft="2dp" />
</LinearLayout>
</LinearLayout>
</ScrollView>
</LinearLayout>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="vertical">

<TextView
android:id="@+id/tvDealer"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Dealer&apos;s Score :- 0"
android:textColor="#ffff00"/>
</LinearLayout>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content">

<ImageSwitcher
android:id="@+id/ivDealerCard1"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>

<ImageSwitcher
android:id="@+id/ivDealerCard2"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>

<ImageSwitcher
android:id="@+id/ivDealerCard3"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>

<ImageSwitcher
android:id="@+id/ivDealerCard4"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>

<ImageSwitcher
android:id="@+id/ivDealerCard5"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>
</LinearLayout>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="vertical">

<TextView
android:id="@+id/tvYou"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Your Score :- 0"
android:textColor="#ffff00"/>
</LinearLayout>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content">

<ImageSwitcher
android:id="@+id/ivYourCard1"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>

<ImageSwitcher
android:id="@+id/ivYourCard2"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>

<ImageSwitcher
android:id="@+id/ivYourCard3"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>

<ImageSwitcher
android:id="@+id/ivYourCard4"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>

<ImageSwitcher
android:id="@+id/ivYourCard5"
android:layout_width="60dp"
android:layout_height="80dp"
android:layout_marginLeft="2dp"/>
</LinearLayout>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center">

<TextView
android:id="@+id/tvBet"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="0"
android:textAppearance="?android:attr/textAppearanceLarge"
android:textColor="#ffff00"/>
</LinearLayout>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center">

<SeekBar
android:id="@+id/sbBetAmount"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingLeft="5dp"
android:paddingRight="5dp"/>
</LinearLayout>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="vertical">

<Button
android:id="@+id/btnPlaceBet"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Place Bet"/>
</LinearLayout>
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="vertical">

<Button
android:id="@+id/btnDoubleDown"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Double Down"/>
</LinearLayout>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center">

<Button
android:id="@+id/btnHit"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight=".3"
android:text="Hit"/>

<Button
android:id="@+id/btnStand"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight=".4"
android:text="Stand"/>

<Button
android:id="@+id/btnSurrender"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight=".4"
android:text="Surrender"/>
</LinearLayout>

<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">

<Button
android:id="@+id/btnExit"
style="?android:attr/buttonStyleSmall"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="50"
android:text="Click to Exit"/>

<Button
android:id="@+id/btnHelp"
style="?android:attr/buttonStyleSmall"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="50"
android:text="How to Play"/>
</LinearLayout>
</LinearLayout>
</ScrollView>

</LinearLayout>
Loading