-
Notifications
You must be signed in to change notification settings - Fork 989
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[MBL-812] Update DiscoveryViewModel to RX2 (#2152)
* initial work to get RX2 updated for discoveryviewmodel (WIP) * WIP remove more RX2 implementation, remove RXView stuff, make discovery work * WIP adjust tests for discoveryViewmodel * update user to always have a value * fix a bunch of tests, one to go * revert changes that broke a couple tests * fix the last test! * remove unused variables, fix logged out container logic for being shown * try adding import to fix circle CI * remove unused import * fix internal tools issue * lint * more lint * STOP IT LINT * update segment tests for new default properties
- Loading branch information
Showing
21 changed files
with
707 additions
and
689 deletions.
There are no files selected for viewing
22 changes: 0 additions & 22 deletions
22
app/src/internal/java/com/kickstarter/libs/InternalTools.java
This file was deleted.
Oops, something went wrong.
17 changes: 17 additions & 0 deletions
17
app/src/internal/java/com/kickstarter/libs/InternalTools.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,17 @@ | ||
package com.kickstarter.libs | ||
|
||
import android.content.Intent | ||
import com.kickstarter.R | ||
import com.kickstarter.ui.activities.InternalToolsActivity | ||
import com.kickstarter.ui.extensions.startActivityWithTransition | ||
|
||
class InternalTools : InternalToolsType { | ||
override fun maybeStartInternalToolsActivity(activity: android.app.Activity) { | ||
val intent = Intent(activity, InternalToolsActivity::class.java) | ||
activity.startActivityWithTransition(intent, R.anim.slide_in_right, R.anim.fade_out_slide_out_left) | ||
} | ||
|
||
override fun basicAuthorizationHeader(): String { | ||
return "Basic ZnV6enk6d3V6enk=" | ||
} | ||
} |
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
9 changes: 0 additions & 9 deletions
9
app/src/main/java/com/kickstarter/libs/InternalToolsType.java
This file was deleted.
Oops, something went wrong.
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,8 @@ | ||
package com.kickstarter.libs | ||
|
||
import android.app.Activity | ||
|
||
interface InternalToolsType { | ||
fun maybeStartInternalToolsActivity(activity: Activity) | ||
fun basicAuthorizationHeader(): String? | ||
} |
14 changes: 0 additions & 14 deletions
14
app/src/main/java/com/kickstarter/libs/NoopInternalTools.java
This file was deleted.
Oops, something went wrong.
11 changes: 11 additions & 0 deletions
11
app/src/main/java/com/kickstarter/libs/NoopInternalTools.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,11 @@ | ||
package com.kickstarter.libs | ||
|
||
import android.app.Activity | ||
|
||
class NoopInternalTools : InternalToolsType { | ||
override fun maybeStartInternalToolsActivity(activity: Activity) {} | ||
|
||
override fun basicAuthorizationHeader(): String? { | ||
return null | ||
} | ||
} |
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
Oops, something went wrong.