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
| import android.content.Context; | |
| import android.content.res.TypedArray; | |
| import android.text.TextUtils; | |
| import android.util.AttributeSet; | |
| import android.view.LayoutInflater; | |
| import android.view.View; | |
| import android.view.ViewTreeObserver; | |
| import android.view.ViewTreeObserver.OnGlobalLayoutListener; | |
| import android.widget.FrameLayout; | |
| import android.widget.TextView; |
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
| Loaded 7643 mappings | |
| gradle/topics/gradle-signing-with-incorrect-key maps to topic 5227 | |
| gradle/topics/how_do_you_use_variables_on_the_eclipse_plugin_to_generate_the_classpath maps to topic 3175 | |
| gradle/topics/why-are-replace-tokens-and-expand-properties-not-part-of-the-inputs-of-the-copy-task maps to topic 5232 | |
| mapping missing for Showing an example of running Selenium2 WebDriver on Groovy using Gradle 245 | |
| gradle/topics/remove-native-build-tasks maps to topic 5231 | |
| gradle/topics/friendlier_way_to_customize_a_generated_pom maps to topic 4968 | |
| gradle/topics/copy_w_duplicatesstrategy_exclude_overwrites_files maps to topic 1945 | |
| mapping missing for Compile groovy with debugging information 5226 | |
| gradle/topics/can-i-tell-which-tasks-were-explicitly-run-i-e-tell-primary-tasks-from-dependencies maps to topic 5228 |
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
| #!/System/Library/Frameworks/Ruby.framework/Versions/Current/usr/bin/ruby | |
| # SET YOUR_HOME TO THE ABSOLUTE PATH OF YOUR HOME DIRECTORY | |
| # chmod +x install.rb | |
| # ./install.rb | |
| YOUR_HOME = '' | |
| HOMEBREW_PREFIX = "#{YOUR_HOME}/usr/local" | |
| HOMEBREW_CACHE = '/Library/Caches/Homebrew' | |
| HOMEBREW_REPO = 'https://github.com/Homebrew/homebrew' |
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
| // get download directory | |
| File imgFile = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS); | |
| if(imgFile.exists()) { | |
| Bitmap myBitmap = BitmapFactory.decodeFile(imgFile.getPath() + "/ovo.jpg"); | |
| ivImagem.setImageBitmap(myBitmap); | |
| } | |
| } |
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
| import android.content.Context; | |
| import android.content.res.TypedArray; | |
| import android.graphics.Canvas; | |
| import android.graphics.Rect; | |
| import android.graphics.drawable.Drawable; | |
| import android.support.v7.widget.LinearLayoutManager; | |
| import android.support.v7.widget.RecyclerView; | |
| import android.util.AttributeSet; | |
| import android.view.View; |
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 static boolean is(Context context) { | |
| try { | |
| ConnectivityManager cm = (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE); | |
| if (cm.getNetworkInfo(ConnectivityManager.TYPE_WIFI).isConnected()) { | |
| return true; | |
| } else if(cm.getNetworkInfo(ConnectivityManager.TYPE_MOBILE).isConnected()){ | |
| return true; | |
| } else { | |
| return 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
| /** | |
| * An enhanced {@code CheckBox} that differentiates between user clicks and | |
| * programmatic clicks. In particular, the {@code OnCheckedChangeListener} is | |
| * <strong>not</strong> triggered when the state of the checkbox is changed | |
| * programmatically. | |
| * | |
| */ | |
| public class EnhancedCheckBox extends CheckBox implements ProgrammaticallyCheckable{ | |
| private CompoundButton.OnCheckedChangeListener mListener = null; | |
| public EnhancedCheckBox(Context 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 class BaseActivity extends AppCompatActivity | |
| { | |
| public DrawerLayout drawerLayout; | |
| public ListView drawerList; | |
| private ActionBarDrawerToggle drawerToggle; | |
| protected void onCreate(Bundle savedInstanceState) | |
| { | |
| // R.id.drawer_layout should be in every activity with exactly the same id. | |
| drawerLayout = (DrawerLayout) findViewById(R.id.drawer_layout); |
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
| <?xml version="1.0" encoding="utf-8"?> | |
| <resources> | |
| <!-- google's material design colours from | |
| http://www.google.com/design/spec/style/color.html#color-ui-color-palette --> | |
| <!--reds--> | |
| <color name="md_red_50">#FFEBEE</color> | |
| <color name="md_red_100">#FFCDD2</color> | |
| <color name="md_red_200">#EF9A9A</color> |