Skip to content

Commit a7e7656

Browse files
committed
Bump version.
1 parent c147ac6 commit a7e7656

File tree

2 files changed

+33
-29
lines changed

2 files changed

+33
-29
lines changed

Readme.md

Lines changed: 31 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -15,28 +15,28 @@ Make sure to add that to your repositories block.
1515

1616
**Gradle**
1717
```gradle
18-
implementation 'com.lazygeniouz:acv:0.3.2'
18+
implementation 'com.lazygeniouz:acv:0.3.4'
1919
```
2020
**Maven**
2121
```xml
2222
<dependency>
23-
<groupId>com.lazygeniouz</groupId>
24-
<artifactId>acv</artifactId>
25-
<version>0.3.2</version>
26-
<type>aar</type>
23+
<groupId>com.lazygeniouz</groupId>
24+
<artifactId>acv</artifactId>
25+
<version>0.3.2</version>
26+
<type>aar</type>
2727
</dependency>
2828
```
2929

3030
## Using `AdContainerView`
3131
### The same old XML Way
3232
```xml
33-
<com.lazygeniouz.acv.AdContainerView
34-
android:id="@+id/adContainerView"
35-
android:layout_width="match_parent"
36-
android:layout_height="wrap_content"
37-
app:acv_autoLoad="true"
38-
app:acv_adSize="ADAPTIVE"
39-
app:acv_adUnitId="@string/test_ad"/>
33+
<com.lazygeniouz.acv.AdContainerView
34+
android:id="@+id/adContainerView"
35+
android:layout_width="match_parent"
36+
android:layout_height="wrap_content"
37+
app:acv_autoLoad="true"
38+
app:acv_adSize="ADAPTIVE"
39+
app:acv_adUnitId="@string/test_ad"/>
4040
```
4141
The attributes are as follows:
4242
* `acv_autoLoad`: Default Value is `false`\
@@ -56,11 +56,11 @@ parentLayout.addView(adContainerView)
5656
**Loading the Ad:**
5757
```kotlin
5858
fun loadAdView(
59-
adUnitId: String,
60-
adSize: AdSize,
61-
adRequest: AdRequest,
62-
parentHasListView: Boolean,
63-
showOnCondition: (() -> Boolean)? = null
59+
adUnitId: String,
60+
adSize: AdSize,
61+
adRequest: AdRequest,
62+
parentHasListView: Boolean,
63+
showOnCondition: (() -> Boolean)? = null
6464
)
6565
```
6666
1. The arguments `adSize` & `adRequest` are optional\
@@ -73,22 +73,26 @@ fun loadAdView(
7373
---
7474
**All other methods:**
7575

76-
* `isLoading(): Boolean`: Returns `true` if the Ad is currently loading, `false` otherwise.
76+
* `@Nullable getAdView()`: Returns the underlying `AdView`, can be `@null` if called before `loadAdView()`.
7777

78-
* `isAdLoaded(): Boolean`: Returns `true` if the Ad is loaded, `false` otherwise.
78+
* `isLoading(): Boolean`: Returns `true` if the Ad is currently loading, `false` otherwise.
7979

80-
* `isVisible(): Boolean`: Returns `true` if the Ad is loaded, not null & visible, `false` otherwise.
80+
* `isAdLoaded(): Boolean`: Returns `true` if the Ad is loaded, `false` otherwise.
8181

82-
* `getAdSize()`: Returns current `adSize`.
82+
* `isVisible(): Boolean`: Returns `true` if the Ad is loaded, not null & visible, `false` otherwise.
8383

84-
* `getAdUnitId()`: Returns current `adUnitId`.
84+
* `getAdSize()`: Returns current `adSize`.
8585

86-
* `setAdListener(listener: AdListener)`: Use the AdView's [`AdListener`](https://developers.google.com/android/reference/com/google/android/gms/ads/AdListener).
86+
* `getAdUnitId()`: Returns current `adUnitId`.
8787

88-
* `removeAd()`: Removes the AdView. Make sure to call `loadAdView()` to re-add `AdView`.
88+
* `setAdListener(listener: AdListener)`: Use the AdView's [`AdListener`](https://developers.google.com/android/reference/com/google/android/gms/ads/AdListener).
8989

90-
* `resumeAd()`: Resumes AdView **(Handled automatically)**
90+
* `@Nullable getAdListener()`: Returns the Listener if set, null otherwise.
9191

92-
* `pauseAd()`: Pauses AdView **(Handled automatically)**
92+
* `removeAd()`: Removes the AdView. Make sure to call `loadAdView()` to re-add `AdView`.
9393

94-
* `destroyAd()`: Destroys AdView **(Handled automatically)**
94+
* `resumeAd()`: Resumes AdView **(Handled automatically)**
95+
96+
* `pauseAd()`: Pauses AdView **(Handled automatically)**
97+
98+
* `destroyAd()`: Destroys AdView **(Handled automatically)**

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import com.vanniktech.maven.publish.*
22

33
buildscript {
4-
ext.kotlin_version = "1.6.21"
4+
ext.kotlin_version = "1.7.0"
55
repositories {
66
google()
77
mavenCentral()
@@ -24,7 +24,7 @@ allprojects {
2424

2525
plugins.withId("com.vanniktech.maven.publish.base") {
2626
group "com.lazygeniouz"
27-
version "0.3.2"
27+
version "0.3.4"
2828

2929
mavenPublishing {
3030
signAllPublications()

0 commit comments

Comments
 (0)