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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
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
val milliSec: Int = getMilliSec() | |
val milliSecStr: String = milliSec.toString() |
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
<?xml version="1.0" encoding="utf-8"?> | |
<LinearLayout | |
xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
xmlns:tools="http://schemas.android.com/tools" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:orientation="vertical" | |
android:background="@color/black" | |
tools:context=".presentation.view.profile.MyProfileFragment"> |
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
<?xml version="1.0" encoding="utf-8"?> | |
<LinearLayout | |
xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:tools="http://schemas.android.com/tools" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:orientation="vertical" | |
tools:context=".presentation.view.profile.MyProfileFragment"> | |
<android.support.v7.widget.Toolbar | |
android:id="@+id/myProfileToolbar" |
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
class MyProfileAdapter( | |
private var items: List<Favorite>, | |
private val myProfileViewModel: MyProfileViewModel, | |
) : RecyclerView.Adapter<RecyclerView.ViewHolder>() { | |
// ----------------- | |
override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): RecyclerView.ViewHolder { | |
when (viewType) { | |
TYPE_HEADER -> { | |
return MyProfileViewHolderHeader(LayoutInflater |
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
class ListUtil: | |
@staticmethod | |
def list_key_exist(sample_list, index): | |
if len(sample_list) > index: | |
print(sample_list[index]) | |
return | |
print("-1") |
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
from typing import List | |
from PIL import Image | |
import os | |
from zipfile import ZipFile, ZIP_DEFLATED | |
import glob | |
class Resize: | |
def __init__(self, root_dir_path: str, resize_param_list: List[object]): |
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
package presentation.utils; | |
import javafx.embed.swing.SwingFXUtils; | |
import javafx.scene.image.ImageView; | |
import javafx.scene.image.WritableImage; | |
import org.apache.batik.transcoder.TranscoderException; | |
import org.apache.batik.transcoder.TranscoderInput; | |
import org.apache.batik.transcoder.image.PNGTranscoder; | |
import java.awt.image.BufferedImage; | |
import java.io.FileNotFoundException; |
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
package presentation; | |
import javafx.application.Application; | |
import javafx.application.Platform; | |
import javafx.concurrent.Task; | |
import javafx.stage.Stage; | |
import presentation.navigator.MenuNavigator; | |
public class MainApp extends Application { |
OlderNewer