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
import com.handmark.pulltorefresh.library.PullToRefreshListView; | |
import android.os.Bundle; | |
import android.support.v4.app.ListFragment; | |
import android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import android.widget.ListView; | |
public class PullToRefreshListFragment extends ListFragment { |
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
final int listViewTopPadding = mListView.getPaddingTop(); | |
for (int i = 0, z = mListView.getChildCount(); i < z; i++) { | |
View child = mListView.getChildAt(i); | |
if (child.getTop() > (listViewTopPadding - child.getHeight()) && child.getTop() <= listViewTopPadding) { | |
// Bingo, we have our first visible child... | |
} | |
} |
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
import android.content.Context; | |
import android.graphics.drawable.Drawable; | |
import android.os.Build.VERSION; | |
import android.os.Build.VERSION_CODES; | |
import android.util.AttributeSet; | |
import android.widget.ImageView; | |
public class OptimisedImageView extends ImageView { | |
private boolean mIgnoreNextRequestLayout = false; |
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
import android.content.Context; | |
import android.util.AttributeSet; | |
import android.widget.ListView; | |
public class BlockingListView extends ListView { | |
private boolean mBlockLayoutChildren; | |
public BlockingListView(Context context) { | |
super(context); |
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 com.example.checkableviews; | |
/******************************************************************************* | |
* Copyright 2013 Chris Banes. | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.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
DecorChildLayout(Context context, ViewGroup systemDecorView, View headerView) { | |
super(context); | |
// Move all children from decor view to here | |
for (int i = 0, z = systemDecorView.getChildCount() ; i < z ; i++) { | |
View child = systemDecorView.getChildAt(i); | |
systemDecorView.removeView(child); | |
addView(child); | |
} |
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
STORE_FILE=/path/to/your.keystore | |
STORE_PASSWORD=yourkeystorepass | |
KEY_ALIAS=projectkeyalias | |
KEY_PASSWORD=keyaliaspassword |
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
/* | |
* Copyright (C) 2006 The Android Open Source Project | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
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
/* | |
* Copyright 2014 Chris Banes | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
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
/* | |
* Copyright (C) 2014 The Android Open Source Project | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
OlderNewer