/* Ċ Ġ* ĠCopyright Ġ( C ) Ġ 2 0 1 9 Ġ- Ġpresent ĠIn structure , ĠInc . Ċ Ġ* Ċ Ġ* ĠĠĠĠ ĠLicensed Ġunder Ġthe ĠApache ĠLicense , ĠVersion Ġ 2 . 0 Ġ( the Ġ" License "); Ċ Ġ* ĠĠĠĠ Ġyou Ġmay Ġnot Ġuse Ġthis Ġfile Ġexcept Ġin Ġcompliance Ġwith Ġthe ĠLicense . Ċ Ġ* ĠĠĠĠ ĠYou Ġmay Ġobtain Ġa Ġcopy Ġof Ġthe ĠLicense Ġat Ċ Ġ* Ċ Ġ* ĠĠĠĠ Ġhttp :// www . apache . org / licenses / LICENSE - 2 . 0 Ċ Ġ* Ċ Ġ* ĠĠĠĠ ĠUnless Ġrequired Ġby Ġapplicable Ġlaw Ġor Ġagreed Ġto Ġin Ġwriting , Ġsoftware Ċ Ġ* ĠĠĠĠ Ġdistributed Ġunder Ġthe ĠLicense Ġis Ġdistributed Ġon Ġan Ġ" AS ĠIS " ĠBASIS , Ċ Ġ* ĠĠĠĠ ĠWITHOUT ĠWARRANTIES ĠOR ĠCONDITIONS ĠOF ĠANY ĠKIND , Ġeither Ġexpress Ġor Ġimplied . Ċ Ġ* ĠĠĠĠ ĠSee Ġthe ĠLicense Ġfor Ġthe Ġspecific Ġlanguage Ġgoverning Ġpermissions Ġand Ċ Ġ* ĠĠĠĠ Ġlimitations Ġunder Ġthe ĠLicense . Ċ Ġ*/ Ċ package Ġcom . in structure . student . mob ius . assignment Details . submission Details . content . empty Submission Ċ Ċ import Ġandroid . app . Activity Ċ import Ġandroid . content . Context Ċ import Ġcom . in structure . canvas api 2 . models . Assignment Ċ import Ġcom . in structure . canvas api 2 . models . Dis cussion Topic Ċ import Ġcom . in structure . canvas api 2 . utils . API Helper Ċ import Ġcom . in structure . canvas api 2 . utils . Api Prefs Ċ import Ġcom . in structure . canvas api 2 . utils . exhaustive Ċ import Ġcom . in structure . student . mob ius . assignment Details .* Ċ import Ġcom . in structure . student . mob ius . assignment Details . submission Details . content . empty Submission . ui . Submission Details Empty Content Fragment Ċ import Ġcom . in structure . student . mob ius . assignment Details . submission Details . content . empty Submission . ui . Submission Details Empty ContentView Ċ import Ġcom . in structure . student . mob ius . common . ui . Effect Handler Ċ import Ġcom . in structure . student . util . getResource Selector Url Ċ Ċ class ĠSubmission Details Empty Content Effect Handler ( val Ġcontext : ĠContext , Ġval Ġassignment Id : ĠLong ) Ġ: ĊĠĠĠ ĠEffect Handler < Submission Details Empty ContentView , ĠSubmission Details Empty Content Event , ĠSubmission Details Empty Content Effect >() Ġ{ ĊĊĠĠĠ Ġoverride Ġfun Ġaccept ( effect : ĠSubmission Details Empty Content Effect ) Ġ{ ĊĠĠĠĠĠĠĠ Ġwhen Ġ( effect ) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ ĠSubmission Details Empty Content Effect . Show Video Recording View Ġ-> Ġcontext . launch Video ({ Submission Details Empty Content Event . Store Video Uri ( it )}, Ġ{ Ġview ?. show Permission Denied Toast () Ġ}, Ġconsumer , ĠSubmission Details Empty Content Fragment . VIDEO _ REQUEST _ CODE ) ĊĠĠĠĠĠĠĠĠĠĠĠ ĠSubmission Details Empty Content Effect . Show Audio Recording View Ġ-> Ġcontext . launch Audio ({ Ġview ?. show Permission Denied Toast () Ġ}, Ġ{ Ġview ?. show Audio Recording View () Ġ}) ĊĠĠĠĠĠĠĠĠĠĠĠ ĠSubmission Details Empty Content Effect . Show Media Picker View Ġ-> Ġlaunch Media Picker () ĊĠĠĠĠĠĠĠĠĠĠĠ ĠSubmission Details Empty Content Effect . Show Video Recording Error Ġ-> Ġview ?. show Video Recording Error () ĊĠĠĠĠĠĠĠĠĠĠĠ ĠSubmission Details Empty Content Effect . Show Audio Recording Error Ġ-> Ġview ?. show Audio Recording Error () ĊĠĠĠĠĠĠĠĠĠĠĠ ĠSubmission Details Empty Content Effect . Show Media Pick ing Error Ġ-> Ġview ?. show Media Pick ing Error () ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠSubmission Details Empty Content Effect . Upload Video Submission Ġ-> Ġview ?. launch File Picker View ( effect . uri , Ġeffect . course , Ġeffect . assignment ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠSubmission Details Empty Content Effect . Upload Media File Submission Ġ-> Ġview ?. launch File Picker View ( effect . uri , Ġeffect . course , Ġeffect . assignment ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠSubmission Details Empty Content Effect . Show Submit Dialog View Ġ-> Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġval Ġstudio Url Ġ= Ġeffect . studio L TI Tool ?. getResource Selector Url ( effect . course , Ġeffect . assignment ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġview ?. show Submit Dialog View ( ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġeffect . assignment , ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġget Submission Types Vis ibilities ( effect . assignment , Ġeffect . is Studio Enabled ), ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġstudio Url , ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġeffect . studio L TI Tool ?. name ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ} ĊĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠSubmission Details Empty Content Effect . Show Quiz Start View Ġ-> Ġview ?. show Quiz Start View ( effect . course , Ġeffect . quiz ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠSubmission Details Empty Content Effect . Show Dis cussion Detail View Ġ-> Ġview ?. show Dis cussion Detail View ( effect . course , Ġeffect . discussion Topic Header Id ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠSubmission Details Empty Content Effect . Upload Audio Submission Ġ-> Ġupload Audio Recording ( context , Ġeffect . file , Ġeffect . assignment , Ġeffect . course ) ĊĠĠĠĠĠĠĠĠĠĠĠ Ġis ĠSubmission Details Empty Content Effect . Show Create Submission View Ġ-> Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġwhen Ġ( effect . submission Type ) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠAssignment . Submission Type . ON LINE _ QUI Z Ġ-> Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġval Ġurl Ġ= ĠAPI Helper . get Quiz URL ( effect . course . id , Ġeffect . assignment . quiz Id ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġview ?. show Quiz Or Dis cussion View ( url ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠAssignment . Submission Type . DIS CU SS ION _ TOPIC Ġ-> Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġval Ġurl Ġ= ĠDis cussion Topic . get Dis cussion URL ( Api Prefs . protocol , ĠApi Prefs . domain , Ġeffect . assignment . course Id , Ġeffect . assignment . discussion Topic Header !!. id ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġview ?. show Quiz Or Dis cussion View ( url ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠAssignment . Submission Type . ON LINE _ UPLOAD Ġ-> Ġview ?. show FileUpload View ( effect . assignment ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠAssignment . Submission Type . ON LINE _ TEXT _ ENTRY Ġ-> Ġview ?. show Online Text Entry View ( effect . assignment . id , Ġeffect . assignment . name ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠAssignment . Submission Type . ON LINE _ URL Ġ-> Ġview ?. show Online Url Entry View ( effect . assignment . id , Ġeffect . assignment . name , Ġeffect . course ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ ĠAssignment . Submission Type . EXTERNAL _ TOOL , ĠAssignment . Submission Type . BASIC _ L TI _ LA UNCH Ġ-> Ġview ?. show L TI View ( effect . course , Ġeffect . lt i Url Ġ?: Ġ"", Ġeffect . assignment . name Ġ?: Ġ"") ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġelse Ġ-> Ġview ?. show Media Recording View () Ġ// Ġe . g . ĠAssignment . Submission Type . MEDIA _ RECORD ING ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ} ĊĠĠĠĠĠĠĠĠĠĠĠ ĠSubmission Details Empty Content Effect . Submission Started Ġ-> Ġview ?. return To Assignment Details () ĊĠĠĠĠĠĠĠ Ġ}. exhaustive ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġprivate Ġfun Ġlaunch Media Picker () Ġ{ ĊĠĠĠĠĠĠ Ġchoose Media Intent . let Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ( context Ġas ĠActivity ). startActivity For Result ( it , ĠSubmission Details Empty Content Fragment . CH OOSE _ MEDIA _ REQUEST _ CODE ) ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} Ċ } Ċ