Skip to content

Instantly share code, notes, and snippets.

@yareally
yareally / SignalStrength.java
Created November 29, 2013 13:21
SignalStrength.java pulled from a crappy LG Esteem (LG-MS910)
package android.telephony;
import android.os.Bundle;
import android.os.Parcel;
import android.os.Parcelable;
import android.os.Parcelable.Creator;
public class SignalStrength
implements Parcelable
{
package com.cc.app.fragments;
import android.app.AlertDialog;
import android.app.Dialog;
import android.app.DialogFragment;
import android.content.DialogInterface;
import android.os.Bundle;
import android.view.View;
import android.widget.*;
import com.cc.app.R;
@yareally
yareally / SignalStrength.java
Created December 6, 2013 16:59
Crappy signal layer from an HTC Thunderbolt running ICS
package android.telephony;
import android.os.Bundle;
import android.os.Parcel;
import android.os.Parcelable;
import android.os.Parcelable.Creator;
import android.util.Log;
public class SignalStrength
implements Parcelable, HtcIfSignalStrength
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Helpers.Storage;
using UnityEngine;
namespace Test
{
@yareally
yareally / ConversationActivity.java
Last active August 29, 2015 14:02
fixes the send button
// original code:
private void initializeIme() {
if (TextSecurePreferences.isEnterImeKeyEnabled(this)) {
composeText.setInputType(composeText.getInputType() & (~InputType.TYPE_TEXT_VARIATION_SHORT_MESSAGE));
} else {
composeText.setInputType(composeText.getInputType() | (InputType.TYPE_TEXT_VARIATION_SHORT_MESSAGE));
}
}
@yareally
yareally / conversation_activity.xml
Last active August 29, 2015 14:02
xml for fixing the send button
<!-- old xml -->
<EditText
android:id="@+id/embedded_text_editor"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1.0"
android:autoText="true"
android:capitalize="sentences"
android:background="#00ffffff"
android:padding="12dp"
@yareally
yareally / SQLiteHelper.cs
Created July 8, 2014 10:54
Wrapper around the .net SQLite library to make working with it easier.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Helpers.Storage
{
@yareally
yareally / dialogs.yml
Created August 21, 2014 10:32
Edit of dialogs.yml for Opera 12 so the startup dialog gives an option to go in offline mode or online mode to avoid loading every tab. The part that was added is the 2 radio buttons in the last StackLayout. Some reason checkbox does not work (yet), but radios do and good enough.
- type: Dialog
name: Startup Dialog
title: D_STARTUP_TITLE
content:
type: StackLayout
name: MainView
elements:
- type: StackLayout # pending proper solution, see DSK-343111
orientation: horizontal
bottom-margin: 16
@yareally
yareally / dialogs.yml
Created August 22, 2014 00:56
Opera 12.12 dialog layout
########## DEFINITIONS ##########
definitions:
widgets:
DoNotShowAgainCheckBox: &DoNotShowAgainCheckBox
type: Checkbox
name: checkbox_Default
string: S_DO_NOT_SHOW_DIALOG_AGAIN
buttons:
# Ok button, typically used in a button strip using *OkButton
@yareally
yareally / override.ini
Last active August 29, 2015 14:05
making search results work correctly on google
Opera Preferences version 2.1
; Do not edit this file while Opera is running
; This file is stored in UTF-8 encoding
; This file is found under c:/users/<username>/appdata/roaming/opera/opera/override.ini
; ~/.opera/ on linux
; or wherever you installed opera (if using the portible version)
; Firefox version was set to version somewhat farther in the future to avoid it not working again anytime soon (version 51)
; add the following lines if they do not already exist to the file:
[Overrides]