This file contains hidden or 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
private static void writeToConnection(HttpURLConnection conn, String message) | |
{ | |
OutputStreamWriter writer; | |
try | |
{ | |
writer = new OutputStreamWriter(conn.getOutputStream()); | |
writer.write(message); | |
writer.flush(); | |
writer.close(); | |
} |
This file contains hidden or 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
/** | |
* Initializes all visual components of the GUI and adds them to the GUI. | |
* Also sets the GUI's settings. | |
*/ | |
private void initVisualComponents() | |
{ | |
this.setTitle("Imgur Uploader"); | |
this.setSize(SIZE_GUI_X, SIZE_GUI_Y); | |
this.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE); | |
this.setResizable(false); |
This file contains hidden or 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
/** | |
* Uses Regex on the provided JSON String to find the 'link' tag. | |
* | |
* @param jsonResponse | |
* The JSON response from Imgur. | |
* @return | |
* The link to the image. | |
*/ | |
private String getLink(String jsonResponse) | |
{ |
This file contains hidden or 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
Desktop desktop = Desktop.isDesktopSupported() ? Desktop.getDesktop() : null; | |
if (desktop != null && desktop.isSupported(Desktop.Action.BROWSE)) | |
{ | |
try | |
{ | |
new URI(url); | |
btnOpenBrowser.setEnabled(true); | |
btnCopyLink.setEnabled(true); | |
} | |
catch (URISyntaxException e) |
This file contains hidden or 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
/** | |
* Captures the currently selected area of the screen and sends it to the | |
* System Clipboard as an image. | |
* | |
* Sets the capture button non-visible so it is not captured in the screenshot. | |
*/ | |
private void captureArea() | |
{ | |
btnCapture.setVisible(false); | |
this.repaint(); |
This file contains hidden or 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 net.dv8tion.android.beekeeper.datatype; | |
public class Frame | |
{ | |
private String name; | |
private int id; | |
private int superId; | |
public String getName() |
This file contains hidden or 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 net.dv8tion.android.beekeeper.datahandler; | |
import java.util.ArrayList; | |
import java.util.List; | |
import net.dv8tion.android.beekeeper.MySQLiteHelper; | |
import net.dv8tion.android.beekeeper.datatype.Comment; | |
import android.content.ContentValues; | |
import android.content.Context; |
This file contains hidden or 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
public void onTickInGame(float f, ats mc) | |
{ | |
try | |
{ | |
this.renderPartialTicks = f; | |
this.currentTimeMillis = System.currentTimeMillis(); | |
GL11.glPushAttrib(1048575); | |
GL11.glPushClientAttrib(-1); | |
GL11.glPushMatrix(); |
This file contains hidden or 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 net.dv8tion.beekeeper; | |
import java.io.Serializable; | |
import java.lang.reflect.ParameterizedType; | |
import java.util.List; | |
import net.dv8tion.android.beekeeper.R; | |
import android.app.ListActivity; | |
import android.content.Intent; | |
import android.os.Bundle; |
This file contains hidden or 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
using System; | |
using UnityEngine; | |
using System.Collections; | |
public class Graph : MonoBehaviour | |
{ | |
private const float LOWER_LIMIT = -1.8f; | |
private const float ZERO = -0.425f; | |
private const float UPPER_LIMIT = .95f; | |
private const float ZERO_TO_LIMIT = 1.375f; |