();
196 | int numListeners = oldListeners.size();
197 | for (int i = 0; i < numListeners; ++i) {
198 | anim.mListeners.add(oldListeners.get(i));
199 | }
200 | }
201 | return anim;
202 | } catch (CloneNotSupportedException e) {
203 | throw new AssertionError();
204 | }
205 | }
206 |
207 | /**
208 | * This method tells the object to use appropriate information to extract
209 | * starting values for the animation. For example, a AnimatorSet object will pass
210 | * this call to its child objects to tell them to set up the values. A
211 | * ObjectAnimator object will use the information it has about its target object
212 | * and PropertyValuesHolder objects to get the start values for its properties.
213 | * An ValueAnimator object will ignore the request since it does not have enough
214 | * information (such as a target object) to gather these values.
215 | */
216 | public void setupStartValues() {
217 | }
218 |
219 | /**
220 | * This method tells the object to use appropriate information to extract
221 | * ending values for the animation. For example, a AnimatorSet object will pass
222 | * this call to its child objects to tell them to set up the values. A
223 | * ObjectAnimator object will use the information it has about its target object
224 | * and PropertyValuesHolder objects to get the start values for its properties.
225 | * An ValueAnimator object will ignore the request since it does not have enough
226 | * information (such as a target object) to gather these values.
227 | */
228 | public void setupEndValues() {
229 | }
230 |
231 | /**
232 | * Sets the target object whose property will be animated by this animation. Not all subclasses
233 | * operate on target objects (for example, {@link ValueAnimator}, but this method
234 | * is on the superclass for the convenience of dealing generically with those subclasses
235 | * that do handle targets.
236 | *
237 | * @param target The object being animated
238 | */
239 | public void setTarget(Object target) {
240 | }
241 |
242 | /**
243 | * An animation listener receives notifications from an animation.
244 | * Notifications indicate animation related events, such as the end or the
245 | * repetition of the animation.
246 | */
247 | public static interface AnimatorListener {
248 | /**
249 | * Notifies the start of the animation.
250 | *
251 | * @param animation The started animation.
252 | */
253 | void onAnimationStart(Animator animation);
254 |
255 | /**
256 | * Notifies the end of the animation. This callback is not invoked
257 | * for animations with repeat count set to INFINITE.
258 | *
259 | * @param animation The animation which reached its end.
260 | */
261 | void onAnimationEnd(Animator animation);
262 |
263 | /**
264 | * Notifies the cancellation of the animation. This callback is not invoked
265 | * for animations with repeat count set to INFINITE.
266 | *
267 | * @param animation The animation which was canceled.
268 | */
269 | void onAnimationCancel(Animator animation);
270 |
271 | /**
272 | * Notifies the repetition of the animation.
273 | *
274 | * @param animation The animation which was repeated.
275 | */
276 | void onAnimationRepeat(Animator animation);
277 | }
278 | }
279 |
--------------------------------------------------------------------------------
/advertlibrary/src/main/java/advert/sdk/com/advertlibrary/wiget/animation/AnimatorListenerAdapter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2010 The Android Open Source Project
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package advert.sdk.com.advertlibrary.wiget.animation;
18 |
19 | /**
20 | * This adapter class provides empty implementations of the methods from {@link android.animation.Animator.AnimatorListener}.
21 | * Any custom listener that cares only about a subset of the methods of this listener can
22 | * simply subclass this adapter class instead of implementing the interface directly.
23 | */
24 | public abstract class AnimatorListenerAdapter implements Animator.AnimatorListener {
25 |
26 | /**
27 | * {@inheritDoc}
28 | */
29 | @Override
30 | public void onAnimationCancel(Animator animation) {
31 | }
32 |
33 | /**
34 | * {@inheritDoc}
35 | */
36 | @Override
37 | public void onAnimationEnd(Animator animation) {
38 | }
39 |
40 | /**
41 | * {@inheritDoc}
42 | */
43 | @Override
44 | public void onAnimationRepeat(Animator animation) {
45 | }
46 |
47 | /**
48 | * {@inheritDoc}
49 | */
50 | @Override
51 | public void onAnimationStart(Animator animation) {
52 | }
53 |
54 | }
55 |
--------------------------------------------------------------------------------
/advertlibrary/src/main/java/advert/sdk/com/advertlibrary/wiget/animation/AnimatorProxy.java:
--------------------------------------------------------------------------------
1 | package advert.sdk.com.advertlibrary.wiget.animation;
2 |
3 | import android.graphics.Camera;
4 | import android.graphics.Matrix;
5 | import android.graphics.RectF;
6 | import android.os.Build;
7 | import android.view.View;
8 | import android.view.animation.Animation;
9 | import android.view.animation.Transformation;
10 |
11 | import java.lang.ref.WeakReference;
12 | import java.util.WeakHashMap;
13 |
14 | /**
15 | * A proxy class to allow for modifying post-3.0 view properties on all pre-3.0
16 | * platforms. DO NOT wrap your views with this class if you
17 | * are using {@code ObjectAnimator} as it will handle that itself.
18 | */
19 | public final class AnimatorProxy extends Animation {
20 | /** Whether or not the current running platform needs to be proxied. */
21 | public static final boolean NEEDS_PROXY = Integer.valueOf(Build.VERSION.SDK).intValue() < Build.VERSION_CODES.HONEYCOMB;
22 |
23 | private static final WeakHashMap PROXIES =
24 | new WeakHashMap();
25 |
26 | /**
27 | * Create a proxy to allow for modifying post-3.0 view properties on all
28 | * pre-3.0 platforms. DO NOT wrap your views if you are
29 | * using {@code ObjectAnimator} as it will handle that itself.
30 | *
31 | * @param view View to wrap.
32 | * @return Proxy to post-3.0 properties.
33 | */
34 | public static AnimatorProxy wrap(View view) {
35 | AnimatorProxy proxy = PROXIES.get(view);
36 | // This checks if the proxy already exists and whether it still is the animation of the given view
37 | if (proxy == null || proxy != view.getAnimation()) {
38 | proxy = new AnimatorProxy(view);
39 | PROXIES.put(view, proxy);
40 | }
41 | return proxy;
42 | }
43 |
44 | private final WeakReference mView;
45 | private final Camera mCamera = new Camera();
46 | private boolean mHasPivot;
47 |
48 | private float mAlpha = 1;
49 | private float mPivotX;
50 | private float mPivotY;
51 | private float mRotationX;
52 | private float mRotationY;
53 | private float mRotationZ;
54 | private float mScaleX = 1;
55 | private float mScaleY = 1;
56 | private float mTranslationX;
57 | private float mTranslationY;
58 |
59 | private final RectF mBefore = new RectF();
60 | private final RectF mAfter = new RectF();
61 | private final Matrix mTempMatrix = new Matrix();
62 |
63 | private AnimatorProxy(View view) {
64 | setDuration(0); //perform transformation immediately
65 | setFillAfter(true); //persist transformation beyond duration
66 | view.setAnimation(this);
67 | mView = new WeakReference(view);
68 | }
69 |
70 | public float getAlpha() {
71 | return mAlpha;
72 | }
73 | public void setAlpha(float alpha) {
74 | if (mAlpha != alpha) {
75 | mAlpha = alpha;
76 | View view = mView.get();
77 | if (view != null) {
78 | view.invalidate();
79 | }
80 | }
81 | }
82 | public float getPivotX() {
83 | return mPivotX;
84 | }
85 | public void setPivotX(float pivotX) {
86 | if (!mHasPivot || mPivotX != pivotX) {
87 | prepareForUpdate();
88 | mHasPivot = true;
89 | mPivotX = pivotX;
90 | invalidateAfterUpdate();
91 | }
92 | }
93 | public float getPivotY() {
94 | return mPivotY;
95 | }
96 | public void setPivotY(float pivotY) {
97 | if (!mHasPivot || mPivotY != pivotY) {
98 | prepareForUpdate();
99 | mHasPivot = true;
100 | mPivotY = pivotY;
101 | invalidateAfterUpdate();
102 | }
103 | }
104 | public float getRotation() {
105 | return mRotationZ;
106 | }
107 | public void setRotation(float rotation) {
108 | if (mRotationZ != rotation) {
109 | prepareForUpdate();
110 | mRotationZ = rotation;
111 | invalidateAfterUpdate();
112 | }
113 | }
114 | public float getRotationX() {
115 | return mRotationX;
116 | }
117 | public void setRotationX(float rotationX) {
118 | if (mRotationX != rotationX) {
119 | prepareForUpdate();
120 | mRotationX = rotationX;
121 | invalidateAfterUpdate();
122 | }
123 | }
124 | public float getRotationY() {
125 | return mRotationY;
126 | }
127 |
128 | public void setRotationY(float rotationY) {
129 | if (mRotationY != rotationY) {
130 | prepareForUpdate();
131 | mRotationY = rotationY;
132 | invalidateAfterUpdate();
133 | }
134 | }
135 | public float getScaleX() {
136 | return mScaleX;
137 | }
138 | public void setScaleX(float scaleX) {
139 | if (mScaleX != scaleX) {
140 | prepareForUpdate();
141 | mScaleX = scaleX;
142 | invalidateAfterUpdate();
143 | }
144 | }
145 | public float getScaleY() {
146 | return mScaleY;
147 | }
148 | public void setScaleY(float scaleY) {
149 | if (mScaleY != scaleY) {
150 | prepareForUpdate();
151 | mScaleY = scaleY;
152 | invalidateAfterUpdate();
153 | }
154 | }
155 | public int getScrollX() {
156 | View view = mView.get();
157 | if (view == null) {
158 | return 0;
159 | }
160 | return view.getScrollX();
161 | }
162 | public void setScrollX(int value) {
163 | View view = mView.get();
164 | if (view != null) {
165 | view.scrollTo(value, view.getScrollY());
166 | }
167 | }
168 | public int getScrollY() {
169 | View view = mView.get();
170 | if (view == null) {
171 | return 0;
172 | }
173 | return view.getScrollY();
174 | }
175 | public void setScrollY(int value) {
176 | View view = mView.get();
177 | if (view != null) {
178 | view.scrollTo(view.getScrollX(), value);
179 | }
180 | }
181 |
182 | public float getTranslationX() {
183 | return mTranslationX;
184 | }
185 | public void setTranslationX(float translationX) {
186 | if (mTranslationX != translationX) {
187 | prepareForUpdate();
188 | mTranslationX = translationX;
189 | invalidateAfterUpdate();
190 | }
191 | }
192 | public float getTranslationY() {
193 | return mTranslationY;
194 | }
195 | public void setTranslationY(float translationY) {
196 | if (mTranslationY != translationY) {
197 | prepareForUpdate();
198 | mTranslationY = translationY;
199 | invalidateAfterUpdate();
200 | }
201 | }
202 | public float getX() {
203 | View view = mView.get();
204 | if (view == null) {
205 | return 0;
206 | }
207 | return view.getLeft() + mTranslationX;
208 | }
209 | public void setX(float x) {
210 | View view = mView.get();
211 | if (view != null) {
212 | setTranslationX(x - view.getLeft());
213 | }
214 | }
215 | public float getY() {
216 | View view = mView.get();
217 | if (view == null) {
218 | return 0;
219 | }
220 | return view.getTop() + mTranslationY;
221 | }
222 | public void setY(float y) {
223 | View view = mView.get();
224 | if (view != null) {
225 | setTranslationY(y - view.getTop());
226 | }
227 | }
228 |
229 | private void prepareForUpdate() {
230 | View view = mView.get();
231 | if (view != null) {
232 | computeRect(mBefore, view);
233 | }
234 | }
235 | private void invalidateAfterUpdate() {
236 | View view = mView.get();
237 | if (view == null || view.getParent() == null) {
238 | return;
239 | }
240 |
241 | final RectF after = mAfter;
242 | computeRect(after, view);
243 | after.union(mBefore);
244 |
245 | ((View)view.getParent()).invalidate(
246 | (int) Math.floor(after.left),
247 | (int) Math.floor(after.top),
248 | (int) Math.ceil(after.right),
249 | (int) Math.ceil(after.bottom));
250 | }
251 |
252 | private void computeRect(final RectF r, View view) {
253 | // compute current rectangle according to matrix transformation
254 | final float w = view.getWidth();
255 | final float h = view.getHeight();
256 |
257 | // use a rectangle at 0,0 to make sure we don't run into issues with scaling
258 | r.set(0, 0, w, h);
259 |
260 | final Matrix m = mTempMatrix;
261 | m.reset();
262 | transformMatrix(m, view);
263 | mTempMatrix.mapRect(r);
264 |
265 | r.offset(view.getLeft(), view.getTop());
266 |
267 | // Straighten coords if rotations flipped them
268 | if (r.right < r.left) {
269 | final float f = r.right;
270 | r.right = r.left;
271 | r.left = f;
272 | }
273 | if (r.bottom < r.top) {
274 | final float f = r.top;
275 | r.top = r.bottom;
276 | r.bottom = f;
277 | }
278 | }
279 |
280 | private void transformMatrix(Matrix m, View view) {
281 | final float w = view.getWidth();
282 | final float h = view.getHeight();
283 | final boolean hasPivot = mHasPivot;
284 | final float pX = hasPivot ? mPivotX : w / 2f;
285 | final float pY = hasPivot ? mPivotY : h / 2f;
286 |
287 | final float rX = mRotationX;
288 | final float rY = mRotationY;
289 | final float rZ = mRotationZ;
290 | if ((rX != 0) || (rY != 0) || (rZ != 0)) {
291 | final Camera camera = mCamera;
292 | camera.save();
293 | camera.rotateX(rX);
294 | camera.rotateY(rY);
295 | camera.rotateZ(-rZ);
296 | camera.getMatrix(m);
297 | camera.restore();
298 | m.preTranslate(-pX, -pY);
299 | m.postTranslate(pX, pY);
300 | }
301 |
302 | final float sX = mScaleX;
303 | final float sY = mScaleY;
304 | if ((sX != 1.0f) || (sY != 1.0f)) {
305 | m.postScale(sX, sY);
306 | final float sPX = -(pX / w) * ((sX * w) - w);
307 | final float sPY = -(pY / h) * ((sY * h) - h);
308 | m.postTranslate(sPX, sPY);
309 | }
310 |
311 | m.postTranslate(mTranslationX, mTranslationY);
312 | }
313 |
314 | @Override
315 | protected void applyTransformation(float interpolatedTime, Transformation t) {
316 | View view = mView.get();
317 | if (view != null) {
318 | t.setAlpha(mAlpha);
319 | transformMatrix(t.getMatrix(), view);
320 | }
321 | }
322 | }
323 |
--------------------------------------------------------------------------------
/advertlibrary/src/main/java/advert/sdk/com/advertlibrary/wiget/animation/ArgbEvaluator.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2010 The Android Open Source Project
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package advert.sdk.com.advertlibrary.wiget.animation;
18 |
19 | import android.animation.TypeEvaluator;
20 |
21 | /**
22 | * This evaluator can be used to perform type interpolation between integer
23 | * values that represent ARGB colors.
24 | */
25 | public class ArgbEvaluator implements TypeEvaluator {
26 |
27 | /**
28 | * This function returns the calculated in-between value for a color
29 | * given integers that represent the start and end values in the four
30 | * bytes of the 32-bit int. Each channel is separately linearly interpolated
31 | * and the resulting calculated values are recombined into the return value.
32 | *
33 | * @param fraction The fraction from the starting to the ending values
34 | * @param startValue A 32-bit int value representing colors in the
35 | * separate bytes of the parameter
36 | * @param endValue A 32-bit int value representing colors in the
37 | * separate bytes of the parameter
38 | * @return A value that is calculated to be the linearly interpolated
39 | * result, derived by separating the start and end values into separate
40 | * color channels and interpolating each one separately, recombining the
41 | * resulting values in the same way.
42 | */
43 | public Object evaluate(float fraction, Object startValue, Object endValue) {
44 | int startInt = (Integer) startValue;
45 | int startA = (startInt >> 24);
46 | int startR = (startInt >> 16) & 0xff;
47 | int startG = (startInt >> 8) & 0xff;
48 | int startB = startInt & 0xff;
49 |
50 | int endInt = (Integer) endValue;
51 | int endA = (endInt >> 24);
52 | int endR = (endInt >> 16) & 0xff;
53 | int endG = (endInt >> 8) & 0xff;
54 | int endB = endInt & 0xff;
55 |
56 | return (int)((startA + (int)(fraction * (endA - startA))) << 24) |
57 | (int)((startR + (int)(fraction * (endR - startR))) << 16) |
58 | (int)((startG + (int)(fraction * (endG - startG))) << 8) |
59 | (int)((startB + (int)(fraction * (endB - startB))));
60 | }
61 | }
--------------------------------------------------------------------------------
/advertlibrary/src/main/java/advert/sdk/com/advertlibrary/wiget/animation/FloatEvaluator.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2010 The Android Open Source Project
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package advert.sdk.com.advertlibrary.wiget.animation;
18 |
19 | import android.animation.TypeEvaluator;
20 |
21 | /**
22 | * This evaluator can be used to perform type interpolation between float
values.
23 | */
24 | public class FloatEvaluator implements TypeEvaluator {
25 |
26 | /**
27 | * This function returns the result of linearly interpolating the start and end values, with
28 | * fraction
representing the proportion between the start and end values. The
29 | * calculation is a simple parametric calculation: result = x0 + t * (v1 - v0)
,
30 | * where x0
is startValue
, x1
is endValue
,
31 | * and t
is fraction
.
32 | *
33 | * @param fraction The fraction from the starting to the ending values
34 | * @param startValue The start value; should be of type float
or
35 | * Float
36 | * @param endValue The end value; should be of type float
or Float
37 | * @return A linear interpolation between the start and end values, given the
38 | * fraction
parameter.
39 | */
40 | public Float evaluate(float fraction, Number startValue, Number endValue) {
41 | float startFloat = startValue.floatValue();
42 | return startFloat + fraction * (endValue.floatValue() - startFloat);
43 | }
44 | }
--------------------------------------------------------------------------------
/advertlibrary/src/main/java/advert/sdk/com/advertlibrary/wiget/animation/IntEvaluator.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2010 The Android Open Source Project
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | */
16 |
17 | package advert.sdk.com.advertlibrary.wiget.animation;
18 |
19 | import android.animation.TypeEvaluator;
20 |
21 | /**
22 | * This evaluator can be used to perform type interpolation between int
values.
23 | */
24 | public class IntEvaluator implements TypeEvaluator {
25 |
26 | /**
27 | * This function returns the result of linearly interpolating the start and end values, with
28 | * fraction
representing the proportion between the start and end values. The
29 | * calculation is a simple parametric calculation: result = x0 + t * (v1 - v0)
,
30 | * where x0
is startValue
, x1
is endValue
,
31 | * and t
is fraction
.
32 | *
33 | * @param fraction The fraction from the starting to the ending values
34 | * @param startValue The start value; should be of type int
or
35 | * Integer
36 | * @param endValue The end value; should be of type int
or Integer
37 | * @return A linear interpolation between the start and end values, given the
38 | * fraction
parameter.
39 | */
40 | public Integer evaluate(float fraction, Integer startValue, Integer endValue) {
41 | int startInt = startValue;
42 | return (int)(startInt + fraction * (endValue - startInt));
43 | }
44 | }
--------------------------------------------------------------------------------
/advertlibrary/src/main/res/anim/dialog_in_anim.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
10 |
--------------------------------------------------------------------------------
/advertlibrary/src/main/res/anim/dialog_out_anim.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
10 |
--------------------------------------------------------------------------------
/advertlibrary/src/main/res/drawable/close.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/advertlibrary/src/main/res/drawable/close.png
--------------------------------------------------------------------------------
/advertlibrary/src/main/res/drawable/closead.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/advertlibrary/src/main/res/drawable/closead.png
--------------------------------------------------------------------------------
/advertlibrary/src/main/res/drawable/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/advertlibrary/src/main/res/drawable/ic_launcher.png
--------------------------------------------------------------------------------
/advertlibrary/src/main/res/layout/dialog_advert_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
12 |
20 |
21 |
--------------------------------------------------------------------------------
/advertlibrary/src/main/res/layout/notification_advert_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
17 |
18 |
25 |
26 |
34 |
35 |
--------------------------------------------------------------------------------
/advertlibrary/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | advertlibrary
3 |
4 |
--------------------------------------------------------------------------------
/advertlibrary/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/app/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/app/app.iml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 | generateDebugSources
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
--------------------------------------------------------------------------------
/app/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.application'
2 |
3 | android {
4 | compileSdkVersion 25
5 | buildToolsVersion "25.0.3"
6 | defaultConfig {
7 | applicationId "advert.sdk.com.advertsdk"
8 | minSdkVersion 19
9 | targetSdkVersion 25
10 | versionCode 1
11 | versionName "1.0"
12 | testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
13 | }
14 | buildTypes {
15 | release {
16 | minifyEnabled false
17 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
18 | }
19 | }
20 | }
21 |
22 | dependencies {
23 | compile fileTree(include: ['*.jar'], dir: 'libs')
24 | androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
25 | exclude group: 'com.android.support', module: 'support-annotations'
26 | })
27 | compile 'com.android.support:appcompat-v7:25.3.1'
28 | compile 'com.android.support.constraint:constraint-layout:1.0.2'
29 | testCompile 'junit:junit:4.12'
30 | compile project(':advertlibrary')
31 | }
32 |
--------------------------------------------------------------------------------
/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in G:\android\sdk/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
19 | # Uncomment this to preserve the line number information for
20 | # debugging stack traces.
21 | #-keepattributes SourceFile,LineNumberTable
22 |
23 | # If you keep the line number information, uncomment this to
24 | # hide the original source file name.
25 | #-renamesourcefileattribute SourceFile
26 |
--------------------------------------------------------------------------------
/app/src/androidTest/java/advert/sdk/com/advertsdk/ExampleInstrumentedTest.java:
--------------------------------------------------------------------------------
1 | package advert.sdk.com.advertsdk;
2 |
3 | import android.content.Context;
4 | import android.support.test.InstrumentationRegistry;
5 | import android.support.test.runner.AndroidJUnit4;
6 |
7 | import org.junit.Test;
8 | import org.junit.runner.RunWith;
9 |
10 | import static org.junit.Assert.*;
11 |
12 | /**
13 | * Instrumentation test, which will execute on an Android device.
14 | *
15 | * @see Testing documentation
16 | */
17 | @RunWith(AndroidJUnit4.class)
18 | public class ExampleInstrumentedTest {
19 | @Test
20 | public void useAppContext() throws Exception {
21 | // Context of the app under test.
22 | Context appContext = InstrumentationRegistry.getTargetContext();
23 |
24 | assertEquals("advert.sdk.com.advertsdk", appContext.getPackageName());
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
9 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/app/src/main/java/advert/sdk/com/advertsdk/MainActivity.java:
--------------------------------------------------------------------------------
1 | package advert.sdk.com.advertsdk;
2 |
3 | import android.os.Bundle;
4 | import android.support.v7.app.AppCompatActivity;
5 | import android.view.View;
6 | import android.widget.Toast;
7 |
8 | public class MainActivity extends AppCompatActivity {
9 |
10 | @Override
11 | protected void onCreate(Bundle savedInstanceState) {
12 | super.onCreate(savedInstanceState);
13 | setContentView(R.layout.activity_main);
14 | findViewById(R.id.btn)
15 | .setOnClickListener(new View.OnClickListener() {
16 | @Override
17 | public void onClick(View v) {
18 | Toast.makeText(MainActivity.this, "不影响点击", Toast.LENGTH_SHORT).show();
19 | }
20 | });
21 |
22 | }
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/app/src/main/java/advert/sdk/com/advertsdk/MyApplication.java:
--------------------------------------------------------------------------------
1 | package advert.sdk.com.advertsdk;
2 |
3 | import android.app.Application;
4 |
5 | import advert.sdk.com.advertlibrary.engine.AdvertEngine;
6 |
7 |
8 | /**
9 | * Created by 18271 on 19/06/2017.
10 | */
11 |
12 | public class MyApplication extends Application{
13 | @Override
14 | public void onCreate() {
15 | super.onCreate();
16 | AdvertEngine.init(this);
17 | }
18 |
19 | }
20 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
14 |
15 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #3F51B5
4 | #303F9F
5 | #FF4081
6 |
7 |
--------------------------------------------------------------------------------
/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | AdvertSDK
3 |
4 |
--------------------------------------------------------------------------------
/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/app/src/test/java/advert/sdk/com/advertsdk/ExampleUnitTest.java:
--------------------------------------------------------------------------------
1 | package advert.sdk.com.advertsdk;
2 |
3 | import org.junit.Test;
4 |
5 | import static org.junit.Assert.*;
6 |
7 | /**
8 | * Example local unit test, which will execute on the development machine (host).
9 | *
10 | * @see Testing documentation
11 | */
12 | public class ExampleUnitTest {
13 | @Test
14 | public void addition_isCorrect() throws Exception {
15 | assertEquals(4, 2 + 2);
16 | }
17 | }
--------------------------------------------------------------------------------
/build.gradle:
--------------------------------------------------------------------------------
1 | // Top-level build file where you can add configuration options common to all sub-projects/modules.
2 |
3 | buildscript {
4 | repositories {
5 | jcenter()
6 | }
7 | dependencies {
8 | classpath 'com.android.tools.build:gradle:2.3.2'
9 |
10 | // NOTE: Do not place your application dependencies here; they belong
11 | // in the individual module build.gradle files
12 | }
13 | }
14 |
15 | allprojects {
16 | repositories {
17 | jcenter()
18 | }
19 | }
20 |
21 | task clean(type: Delete) {
22 | delete rootProject.buildDir
23 | }
24 |
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-20-14-03-13-285.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-20-14-03-13-285.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-20-14-03-51-500.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-20-14-03-51-500.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-20-14-10-25-038.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-20-14-10-25-038.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-20-14-59-50-758.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-20-14-59-50-758.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-20-15-10-10-730.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-20-15-10-10-730.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-20-15-21-52-704.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-20-15-21-52-704.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-20-17-31-03-957.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-20-17-31-03-957.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-20-17-31-11-327.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-20-17-31-11-327.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-20-17-31-41-376.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-20-17-31-41-376.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-11-50-45-069.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-11-50-45-069.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-11-50-52-037.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-11-50-52-037.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-02-27-594.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-02-27-594.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-02-33-939.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-02-33-939.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-25-33-786.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-25-33-786.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-27-36-179.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-27-36-179.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-30-32-760.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-30-32-760.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-32-23-270.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-32-23-270.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-39-20-832.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-39-20-832.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-39-27-940.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-39-27-940.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-51-47-558.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-51-47-558.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-52-15-072.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-52-15-072.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-17-54-54-007.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-17-54-54-007.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-18-01-15-894.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-18-01-15-894.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-21-18-01-38-435.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-21-18-01-38-435.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-22-09-16-07-058.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-22-09-16-07-058.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-22-09-16-12-711.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-22-09-16-12-711.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-22-10-21-08-419.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-22-10-21-08-419.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-22-10-21-12-030.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-22-10-21-12-030.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-22-10-25-58-365.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-22-10-25-58-365.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-23-14-00-57-334.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-23-14-00-57-334.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-23-14-00-59-865.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-23-14-00-59-865.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-23-14-03-04-468.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-23-14-03-04-468.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-23-14-33-23-503.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-23-14-33-23-503.rawproto
--------------------------------------------------------------------------------
/build/android-profile/profile-2017-06-23-14-33-25-351.rawproto:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/android-profile/profile-2017-06-23-14-33-25-351.rawproto
--------------------------------------------------------------------------------
/build/generated/mockable-android-25.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/build/generated/mockable-android-25.jar
--------------------------------------------------------------------------------
/build/intermediates/dex-cache/cache.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
11 |
12 |
13 | -
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 |
3 | # IDE (e.g. Android Studio) users:
4 | # Gradle settings configured through the IDE *will override*
5 | # any settings specified in this file.
6 |
7 | # For more details on how to configure your build environment visit
8 | # http://www.gradle.org/docs/current/userguide/build_environment.html
9 |
10 | # Specifies the JVM arguments used for the daemon process.
11 | # The setting is particularly useful for tweaking memory settings.
12 | org.gradle.jvmargs=-Xmx1536m
13 |
14 | # When configured, Gradle will run in incubating parallel mode.
15 | # This option should only be used with decoupled projects. More details, visit
16 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
17 | # org.gradle.parallel=true
18 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/15527621771/Android-Advert-SDK/c7e117e04d3a4de175ae35f7f65c785ccb305b67/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Mon Jun 19 14:51:21 CST 2017
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-3.3-all.zip
7 |
--------------------------------------------------------------------------------
/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | ##############################################################################
4 | ##
5 | ## Gradle start up script for UN*X
6 | ##
7 | ##############################################################################
8 |
9 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
10 | DEFAULT_JVM_OPTS=""
11 |
12 | APP_NAME="Gradle"
13 | APP_BASE_NAME=`basename "$0"`
14 |
15 | # Use the maximum available, or set MAX_FD != -1 to use that value.
16 | MAX_FD="maximum"
17 |
18 | warn ( ) {
19 | echo "$*"
20 | }
21 |
22 | die ( ) {
23 | echo
24 | echo "$*"
25 | echo
26 | exit 1
27 | }
28 |
29 | # OS specific support (must be 'true' or 'false').
30 | cygwin=false
31 | msys=false
32 | darwin=false
33 | case "`uname`" in
34 | CYGWIN* )
35 | cygwin=true
36 | ;;
37 | Darwin* )
38 | darwin=true
39 | ;;
40 | MINGW* )
41 | msys=true
42 | ;;
43 | esac
44 |
45 | # Attempt to set APP_HOME
46 | # Resolve links: $0 may be a link
47 | PRG="$0"
48 | # Need this for relative symlinks.
49 | while [ -h "$PRG" ] ; do
50 | ls=`ls -ld "$PRG"`
51 | link=`expr "$ls" : '.*-> \(.*\)$'`
52 | if expr "$link" : '/.*' > /dev/null; then
53 | PRG="$link"
54 | else
55 | PRG=`dirname "$PRG"`"/$link"
56 | fi
57 | done
58 | SAVED="`pwd`"
59 | cd "`dirname \"$PRG\"`/" >/dev/null
60 | APP_HOME="`pwd -P`"
61 | cd "$SAVED" >/dev/null
62 |
63 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
64 |
65 | # Determine the Java command to use to start the JVM.
66 | if [ -n "$JAVA_HOME" ] ; then
67 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
68 | # IBM's JDK on AIX uses strange locations for the executables
69 | JAVACMD="$JAVA_HOME/jre/sh/java"
70 | else
71 | JAVACMD="$JAVA_HOME/bin/java"
72 | fi
73 | if [ ! -x "$JAVACMD" ] ; then
74 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
75 |
76 | Please set the JAVA_HOME variable in your environment to match the
77 | location of your Java installation."
78 | fi
79 | else
80 | JAVACMD="java"
81 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
82 |
83 | Please set the JAVA_HOME variable in your environment to match the
84 | location of your Java installation."
85 | fi
86 |
87 | # Increase the maximum file descriptors if we can.
88 | if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
89 | MAX_FD_LIMIT=`ulimit -H -n`
90 | if [ $? -eq 0 ] ; then
91 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
92 | MAX_FD="$MAX_FD_LIMIT"
93 | fi
94 | ulimit -n $MAX_FD
95 | if [ $? -ne 0 ] ; then
96 | warn "Could not set maximum file descriptor limit: $MAX_FD"
97 | fi
98 | else
99 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
100 | fi
101 | fi
102 |
103 | # For Darwin, add options to specify how the application appears in the dock
104 | if $darwin; then
105 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
106 | fi
107 |
108 | # For Cygwin, switch paths to Windows format before running java
109 | if $cygwin ; then
110 | APP_HOME=`cygpath --path --mixed "$APP_HOME"`
111 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
112 | JAVACMD=`cygpath --unix "$JAVACMD"`
113 |
114 | # We build the pattern for arguments to be converted via cygpath
115 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
116 | SEP=""
117 | for dir in $ROOTDIRSRAW ; do
118 | ROOTDIRS="$ROOTDIRS$SEP$dir"
119 | SEP="|"
120 | done
121 | OURCYGPATTERN="(^($ROOTDIRS))"
122 | # Add a user-defined pattern to the cygpath arguments
123 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then
124 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
125 | fi
126 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
127 | i=0
128 | for arg in "$@" ; do
129 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
130 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
131 |
132 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
133 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
134 | else
135 | eval `echo args$i`="\"$arg\""
136 | fi
137 | i=$((i+1))
138 | done
139 | case $i in
140 | (0) set -- ;;
141 | (1) set -- "$args0" ;;
142 | (2) set -- "$args0" "$args1" ;;
143 | (3) set -- "$args0" "$args1" "$args2" ;;
144 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
145 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
146 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
147 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
148 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
149 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
150 | esac
151 | fi
152 |
153 | # Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
154 | function splitJvmOpts() {
155 | JVM_OPTS=("$@")
156 | }
157 | eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
158 | JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
159 |
160 | exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
161 |
--------------------------------------------------------------------------------
/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
12 | set DEFAULT_JVM_OPTS=
13 |
14 | set DIRNAME=%~dp0
15 | if "%DIRNAME%" == "" set DIRNAME=.
16 | set APP_BASE_NAME=%~n0
17 | set APP_HOME=%DIRNAME%
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windowz variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 | if "%@eval[2+2]" == "4" goto 4NT_args
53 |
54 | :win9xME_args
55 | @rem Slurp the command line arguments.
56 | set CMD_LINE_ARGS=
57 | set _SKIP=2
58 |
59 | :win9xME_args_slurp
60 | if "x%~1" == "x" goto execute
61 |
62 | set CMD_LINE_ARGS=%*
63 | goto execute
64 |
65 | :4NT_args
66 | @rem Get arguments from the 4NT Shell from JP Software
67 | set CMD_LINE_ARGS=%$
68 |
69 | :execute
70 | @rem Setup the command line
71 |
72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
73 |
74 | @rem Execute Gradle
75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
76 |
77 | :end
78 | @rem End local scope for the variables with windows NT shell
79 | if "%ERRORLEVEL%"=="0" goto mainEnd
80 |
81 | :fail
82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
83 | rem the _cmd.exe /c_ return code!
84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
85 | exit /b 1
86 |
87 | :mainEnd
88 | if "%OS%"=="Windows_NT" endlocal
89 |
90 | :omega
91 |
--------------------------------------------------------------------------------
/local.properties:
--------------------------------------------------------------------------------
1 | ## This file is automatically generated by Android Studio.
2 | # Do not modify this file -- YOUR CHANGES WILL BE ERASED!
3 | #
4 | # This file must *NOT* be checked into Version Control Systems,
5 | # as it contains information specific to your local configuration.
6 | #
7 | # Location of the SDK. This is only used by Gradle.
8 | # For customization when using a Version Control System, please read the
9 | # header note.
10 | #Wed Jun 21 17:39:19 CST 2017
11 | sdk.dir=C\:\\androidsdk\\sdk1122-lite
12 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app', ':advertlibrary'
2 |
--------------------------------------------------------------------------------