-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #41 from StepicOrg/release/1.8
Release/1.8
- Loading branch information
Showing
79 changed files
with
1,351 additions
and
735 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
app/src/main/java/org/stepic/droid/concurrency/DownloadPoster.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package org.stepic.droid.concurrency | ||
|
||
import com.squareup.otto.Bus | ||
|
||
import org.stepic.droid.base.MainApplication | ||
import org.stepic.droid.events.video.DownloadReportEvent | ||
import org.stepic.droid.model.DownloadingVideoItem | ||
|
||
import javax.inject.Inject | ||
|
||
class DownloadPoster(private val downloadingVideoItem: DownloadingVideoItem) : Function0<Unit> { | ||
|
||
@Inject | ||
lateinit var bus: Bus | ||
|
||
init { | ||
MainApplication.component().inject(this) | ||
} | ||
|
||
override fun invoke(): Unit { | ||
bus.post(DownloadReportEvent(downloadingVideoItem)) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 4 additions & 0 deletions
4
app/src/main/java/org/stepic/droid/events/CancelAllVideosEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
package org.stepic.droid.events; | ||
|
||
public class CancelAllVideosEvent { | ||
} |
13 changes: 13 additions & 0 deletions
13
app/src/main/java/org/stepic/droid/events/DownloadingIsLoadedSuccessfullyEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
package org.stepic.droid.events; | ||
|
||
public class DownloadingIsLoadedSuccessfullyEvent { | ||
long downloadId; | ||
|
||
public DownloadingIsLoadedSuccessfullyEvent(long downloadId) { | ||
this.downloadId = downloadId; | ||
} | ||
|
||
public long getDownloadId() { | ||
return downloadId; | ||
} | ||
} |
3 changes: 3 additions & 0 deletions
3
app/src/main/java/org/stepic/droid/events/loading/FinishDeletingLoadEvent.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package org.stepic.droid.events.loading | ||
|
||
class FinishDeletingLoadEvent |
3 changes: 3 additions & 0 deletions
3
app/src/main/java/org/stepic/droid/events/loading/StartDeletingLoadEvent.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package org.stepic.droid.events.loading | ||
|
||
class StartDeletingLoadEvent |
4 changes: 2 additions & 2 deletions
4
app/src/main/java/org/stepic/droid/model/DownloadReportItem.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.