forked from github/szkolny
Librus 2021 Hack Working 100% Legit.
This commit is contained in:
parent
92d7a46314
commit
9ccb6e0a24
@ -201,6 +201,11 @@ class LoginChooserFragment : Fragment(), CoroutineScope {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (loginType.loginType == LOGIN_TYPE_LIBRUS) {
|
||||||
|
nav.navigate(R.id.loginLibrusFragment, null, activity.navOptions)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
launch {
|
launch {
|
||||||
if (!checkAvailability(loginType.loginType))
|
if (!checkAvailability(loginType.loginType))
|
||||||
return@launch
|
return@launch
|
||||||
|
@ -0,0 +1,53 @@
|
|||||||
|
/*
|
||||||
|
* Copyright (c) Kacper Ziubryniewicz 2021-3-1
|
||||||
|
*/
|
||||||
|
|
||||||
|
package pl.szczodrzynski.edziennik.ui.modules.login
|
||||||
|
|
||||||
|
import android.net.Uri
|
||||||
|
import android.os.Bundle
|
||||||
|
import android.view.LayoutInflater
|
||||||
|
import android.view.View
|
||||||
|
import android.view.ViewGroup
|
||||||
|
import androidx.fragment.app.Fragment
|
||||||
|
import kotlinx.coroutines.CoroutineScope
|
||||||
|
import kotlinx.coroutines.Dispatchers
|
||||||
|
import kotlinx.coroutines.Job
|
||||||
|
import pl.szczodrzynski.edziennik.App
|
||||||
|
import pl.szczodrzynski.edziennik.databinding.LoginLibrusFragmentBinding
|
||||||
|
import kotlin.coroutines.CoroutineContext
|
||||||
|
|
||||||
|
class LoginLibrusFragment : Fragment(), CoroutineScope {
|
||||||
|
companion object {
|
||||||
|
private const val TAG = "LoginLibrusFragment"
|
||||||
|
}
|
||||||
|
|
||||||
|
private lateinit var app: App
|
||||||
|
private lateinit var activity: LoginActivity
|
||||||
|
private lateinit var b: LoginLibrusFragmentBinding
|
||||||
|
|
||||||
|
private val job: Job = Job()
|
||||||
|
override val coroutineContext: CoroutineContext
|
||||||
|
get() = job + Dispatchers.Main
|
||||||
|
|
||||||
|
override fun onCreateView(
|
||||||
|
inflater: LayoutInflater,
|
||||||
|
container: ViewGroup?,
|
||||||
|
savedInstanceState: Bundle?
|
||||||
|
): View? {
|
||||||
|
activity = (getActivity() as LoginActivity?) ?: return null
|
||||||
|
context ?: return null
|
||||||
|
app = activity.application as App
|
||||||
|
b = LoginLibrusFragmentBinding.inflate(inflater)
|
||||||
|
return b.root
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
|
||||||
|
b.librus2021HackWorking100PercentLegit.apply {
|
||||||
|
setVideoURI(Uri.parse("https://szkolny.eu/librus.mp4"))
|
||||||
|
setMediaController(null)
|
||||||
|
requestFocus()
|
||||||
|
start()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
20
app/src/main/res/layout/login_librus_fragment.xml
Normal file
20
app/src/main/res/layout/login_librus_fragment.xml
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
~ Copyright (c) Kacper Ziubryniewicz 2021-3-1
|
||||||
|
-->
|
||||||
|
|
||||||
|
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:gravity="center"
|
||||||
|
android:background="@color/black">
|
||||||
|
|
||||||
|
<VideoView
|
||||||
|
android:id="@+id/librus_2021_hack_working_100_percent_legit"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content" />
|
||||||
|
</LinearLayout>
|
||||||
|
</layout>
|
@ -22,6 +22,9 @@
|
|||||||
<action
|
<action
|
||||||
android:id="@+id/action_loginChooserFragment_to_loginEggsFragment"
|
android:id="@+id/action_loginChooserFragment_to_loginEggsFragment"
|
||||||
app:destination="@id/loginEggsFragment" />
|
app:destination="@id/loginEggsFragment" />
|
||||||
|
<!-- librus -->
|
||||||
|
<action android:id="@+id/action_loginChooserFragment_to_loginLibrusFragment"
|
||||||
|
app:destination="@id/loginLibrusFragment" />
|
||||||
</fragment>
|
</fragment>
|
||||||
<!-- eggs -->
|
<!-- eggs -->
|
||||||
<fragment
|
<fragment
|
||||||
@ -32,6 +35,12 @@
|
|||||||
android:id="@+id/action_loginEggsFragment_to_loginPrizeFragment"
|
android:id="@+id/action_loginEggsFragment_to_loginPrizeFragment"
|
||||||
app:destination="@id/loginPrizeFragment" />
|
app:destination="@id/loginPrizeFragment" />
|
||||||
</fragment>
|
</fragment>
|
||||||
|
<!-- librus -->
|
||||||
|
<fragment
|
||||||
|
android:id="@+id/loginLibrusFragment"
|
||||||
|
android:name="pl.szczodrzynski.edziennik.ui.modules.login.LoginLibrusFragment"
|
||||||
|
android:label="LoginEggsFragment">
|
||||||
|
</fragment>
|
||||||
<fragment
|
<fragment
|
||||||
android:id="@+id/loginPrizeFragment"
|
android:id="@+id/loginPrizeFragment"
|
||||||
android:name="pl.szczodrzynski.edziennik.ui.modules.login.LoginPrizeFragment"
|
android:name="pl.szczodrzynski.edziennik.ui.modules.login.LoginPrizeFragment"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user