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
public class MainWindow { | |
public static void main(String[] args) { | |
// Write code that creates a window with a button | |
} | |
} |
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
public class MainWindow { | |
public static void main(String args[]) { | |
SwingUtilities.invokeLater(new Runnable()) { | |
JFrame f = new JFrame("Color Selector Test"); | |
f.add(new MainPanel()); | |
f.pack(); | |
f.setVisible(true); | |
} | |
} | |
} |
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
albumCover.setOnTouchListener(new OnTouchListener() { | |
public void onTouch(View v, MotionEvent event) { | |
// What happens when an albumCover is touched | |
} | |
}); | |
channelName.setOnTouchListener(new OnTouchListener() { | |
public void onTouch(View v, MotionEvent event) { | |
// What happens when an channelName is touched | |
} |
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
successes = 0 | |
failures = 0 | |
for sfMilestone in data["milestones"]: | |
ghMilestone = milestone.sf2github(sfMilestone) | |
response = requests.post( | |
'https://api.github.com/repos/' + username + '/' + repo + '/milestones', | |
data=json.dumps(ghMilestone), | |
auth=(username, password)) |
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
milestoneNumbers = {} | |
for state in ['open', 'closed']: | |
print("***" + state) | |
stateJSON = {'state' : state} | |
print(json.dumps(stateJSON)) | |
response = requests.get( | |
'https://api.github.com/repos/' + username + '/' + repo + '/milestones', | |
data=json.dumps(stateJSON), | |
auth=(username, password)) |
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
sfTicket = [ticket for ticket in sfTickets if ticket['summary'] == issue['title']][0] | |
pprint(sfTicket['custom_fields']['_milestone']) | |
updateData = {'title' : issue['title']} | |
updateData['milestone'] = milestoneNumbers[sfTicket['custom_fields']['_milestone']] |
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 codeguru.connect4; | |
import com.badlogic.gdx.graphics.OrthographicCamera; | |
import com.badlogic.gdx.ApplicationListener; | |
import com.badlogic.gdx.Gdx; | |
import com.badlogic.gdx.graphics.Color; | |
import com.badlogic.gdx.graphics.GL10; | |
import com.badlogic.gdx.graphics.glutils.ShapeRenderer; | |
import com.badlogic.gdx.graphics.glutils.ShapeRenderer.ShapeType; |
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
set = do | |
char '{' | |
result <- list | |
char '}' | |
return result | |
list = sepBy1 cell (char ',') | |
cell = many (noneOf ",}") | |
parseSet :: String -> Either ParseError [String] |
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
java.lang.SecurityException: Injecting to another application requires INJECT_EVENTS permission | |
at android.os.Parcel.readException(Parcel.java:1425) | |
at android.os.Parcel.readException(Parcel.java:1379) | |
at android.hardware.input.IInputManager$Stub$Proxy.injectInputEvent(IInputManager.java:356) | |
at android.hardware.input.InputManager.injectInputEvent(InputManager.java:619) | |
at android.app.Instrumentation.sendKeySync(Instrumentation.java:886) | |
at android.app.Instrumentation.sendStringSync(Instrumentation.java:848) | |
at bbct.android.common.test.BBCTTestUtil.sendKeysToCurrFieldCardDetails(BBCTTestUtil.java:296) | |
at bbct.android.common.test.BBCTTestUtil.sendKeysToCardDetails(BBCTTestUtil.java:225) | |
at bbct.android.common.test.BBCTTestUtil.sendKeysToCardDetails(BBCTTestUtil.java:204) |
We can make this file beautiful and searchable if this error is corrected: No commas found in this CSV file in line 0.
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
1|Topps|1991|278|10000|1|Alex Fernandez|White Sox|Pitcher | |
2|Topps|1974|175|10000|1|Bob Stanley|Red Sox|Pitcher | |
3|Topps|1985|201|10000|1|Vince Coleman|Cardinals|Pitcher | |
4|TMG|1993|5|10000|1|Ken Griffey Jr.|All-Star|Pitcher | |
5|Upper Deck|1993|18|10000|1|Dave Hollins|Phillies|Pitcher | |
6|Upper Deck|1990|189|10000|1|Tom Browning|Reds|Pitcher | |
7|Topps|1982|121|10000|1|Ed Lynch|Mets|Pitcher |
OlderNewer