fixed #230
|
@ -54,6 +54,7 @@ import org.apache.commons.lang3.StringUtils;
|
|||
import org.mariotaku.twidere.R;
|
||||
import org.mariotaku.twidere.adapter.ArrayAdapter;
|
||||
import org.mariotaku.twidere.util.ParseUtils;
|
||||
import org.mariotaku.twidere.util.SharedPreferencesWrapper;
|
||||
import org.mariotaku.twidere.util.ThemeUtils;
|
||||
|
||||
import java.util.Map;
|
||||
|
@ -70,12 +71,15 @@ public class HostMappingsListFragment extends BaseListFragment implements MultiC
|
|||
|
||||
private ListView mListView;
|
||||
private HostMappingAdapter mAdapter;
|
||||
private SharedPreferencesWrapper mHostMapping;
|
||||
|
||||
@Override
|
||||
public void onActivityCreated(final Bundle savedInstanceState) {
|
||||
super.onActivityCreated(savedInstanceState);
|
||||
setHasOptionsMenu(true);
|
||||
mPreferences.registerOnSharedPreferenceChangeListener(this);
|
||||
mHostMapping = SharedPreferencesWrapper.getInstance(getActivity(),
|
||||
HOST_MAPPING_PREFERENCES_NAME, Context.MODE_PRIVATE);
|
||||
mHostMapping.registerOnSharedPreferenceChangeListener(this);
|
||||
mAdapter = new HostMappingAdapter(getActivity());
|
||||
setListAdapter(mAdapter);
|
||||
mListView = getListView();
|
||||
|
@ -100,7 +104,7 @@ public class HostMappingsListFragment extends BaseListFragment implements MultiC
|
|||
public boolean onActionItemClicked(final ActionMode mode, final MenuItem item) {
|
||||
switch (item.getItemId()) {
|
||||
case R.id.delete: {
|
||||
final SharedPreferences.Editor editor = mPreferences.edit();
|
||||
final SharedPreferences.Editor editor = mHostMapping.edit();
|
||||
final SparseBooleanArray array = mListView.getCheckedItemPositions();
|
||||
if (array == null) return false;
|
||||
for (int i = 0, size = array.size(); i < size; i++) {
|
||||
|
|
|
@ -272,8 +272,8 @@ import static org.mariotaku.twidere.util.TwidereLinkify.TWITTER_PROFILE_IMAGES_A
|
|||
public final class Utils implements Constants {
|
||||
|
||||
public static final Pattern PATTERN_XML_RESOURCE_IDENTIFIER = Pattern.compile("res/xml/([\\w_]+)\\.xml");
|
||||
|
||||
public static final Pattern PATTERN_RESOURCE_IDENTIFIER = Pattern.compile("@([\\w_]+)/([\\w_]+)");
|
||||
|
||||
private static final UriMatcher CONTENT_PROVIDER_URI_MATCHER = new UriMatcher(UriMatcher.NO_MATCH);
|
||||
private static final UriMatcher LINK_HANDLER_URI_MATCHER = new UriMatcher(UriMatcher.NO_MATCH);
|
||||
private static final UriMatcher HOME_TABS_URI_MATCHER = new UriMatcher(UriMatcher.NO_MATCH);
|
||||
|
|
After Width: | Height: | Size: 428 B |
After Width: | Height: | Size: 515 B |
After Width: | Height: | Size: 431 B |
After Width: | Height: | Size: 357 B |
After Width: | Height: | Size: 779 B |
After Width: | Height: | Size: 352 B |
After Width: | Height: | Size: 420 B |
After Width: | Height: | Size: 314 B |
After Width: | Height: | Size: 272 B |
After Width: | Height: | Size: 553 B |
After Width: | Height: | Size: 480 B |
After Width: | Height: | Size: 593 B |
After Width: | Height: | Size: 469 B |
After Width: | Height: | Size: 377 B |
After Width: | Height: | Size: 966 B |
After Width: | Height: | Size: 566 B |
After Width: | Height: | Size: 744 B |
After Width: | Height: | Size: 575 B |
After Width: | Height: | Size: 457 B |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 587 B |
After Width: | Height: | Size: 897 B |
After Width: | Height: | Size: 694 B |
After Width: | Height: | Size: 533 B |
After Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 184 B |
Before Width: | Height: | Size: 195 B |
Before Width: | Height: | Size: 162 B |
Before Width: | Height: | Size: 357 B |
Before Width: | Height: | Size: 165 B |
Before Width: | Height: | Size: 132 B |
Before Width: | Height: | Size: 119 B |
Before Width: | Height: | Size: 238 B |
Before Width: | Height: | Size: 267 B |
Before Width: | Height: | Size: 201 B |
Before Width: | Height: | Size: 177 B |
Before Width: | Height: | Size: 457 B |
Before Width: | Height: | Size: 293 B |
Before Width: | Height: | Size: 241 B |
Before Width: | Height: | Size: 191 B |
Before Width: | Height: | Size: 532 B |
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg width="32px" height="32px" viewBox="0 0 32 32" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
||||
<!-- Generator: Sketch 3.4 (15588) - http://www.bohemiancoding.com/sketch -->
|
||||
<title>Artboard</title>
|
||||
<desc>Created with Sketch.</desc>
|
||||
<defs></defs>
|
||||
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
||||
<g id="Artboard" sketch:type="MSArtboardGroup" fill="#FFFFFF">
|
||||
<path d="M24,15 L11.83,15 L17.42,9.41 L16,8 L8,16 L16,24 L17.41,22.59 L11.83,17 L24,17 L24,15 L24,15 Z" id="Shape" sketch:type="MSShapeGroup"></path>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 786 B |
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg width="32px" height="32px" viewBox="0 0 32 32" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
||||
<!-- Generator: Sketch 3.4 (15588) - http://www.bohemiancoding.com/sketch -->
|
||||
<title>Artboard</title>
|
||||
<desc>Created with Sketch.</desc>
|
||||
<defs></defs>
|
||||
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
||||
<g id="Artboard" sketch:type="MSArtboardGroup" fill="#FFFFFF">
|
||||
<path d="M23,10.41 L21.59,9 L16,14.59 L10.41,9 L9,10.41 L14.59,16 L9,21.59 L10.41,23 L16,17.41 L21.59,23 L23,21.59 L17.41,16 L23,10.41 Z" id="Shape" sketch:type="MSShapeGroup"></path>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 820 B |
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg width="32px" height="32px" viewBox="0 0 32 32" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
||||
<!-- Generator: Sketch 3.4 (15588) - http://www.bohemiancoding.com/sketch -->
|
||||
<title>Artboard</title>
|
||||
<desc>Created with Sketch.</desc>
|
||||
<defs></defs>
|
||||
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
||||
<g id="Artboard" sketch:type="MSArtboardGroup" fill="#FFFFFF">
|
||||
<path d="M20,5 L8,5 C6.9,5 6,5.9 6,7 L6,21 L8,21 L8,7 L20,7 L20,5 L20,5 Z M23,9 L12,9 C10.9,9 10,9.9 10,11 L10,25 C10,26.1 10.9,27 12,27 L23,27 C24.1,27 25,26.1 25,25 L25,11 C25,9.9 24.1,9 23,9 L23,9 Z M23,25 L12,25 L12,11 L23,11 L23,25 L23,25 Z" id="Shape" sketch:type="MSShapeGroup"></path>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 929 B |
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg width="32px" height="32px" viewBox="0 0 32 32" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
||||
<!-- Generator: Sketch 3.4 (15588) - http://www.bohemiancoding.com/sketch -->
|
||||
<title>Artboard</title>
|
||||
<desc>Created with Sketch.</desc>
|
||||
<defs></defs>
|
||||
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
||||
<g id="Artboard" sketch:type="MSArtboardGroup" fill="#FFFFFF">
|
||||
<path d="M10,23 C10,24.1 10.9,25 12,25 L20,25 C21.1,25 22,24.1 22,23 L22,11 L10,11 L10,23 L10,23 Z M23,8 L19.5,8 L18.5,7 L13.5,7 L12.5,8 L9,8 L9,10 L23,10 L23,8 L23,8 Z" id="Shape" sketch:type="MSShapeGroup"></path>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 852 B |
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg width="32px" height="32px" viewBox="0 0 32 32" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
||||
<!-- Generator: Sketch 3.4 (15588) - http://www.bohemiancoding.com/sketch -->
|
||||
<title>Artboard</title>
|
||||
<desc>Created with Sketch.</desc>
|
||||
<defs></defs>
|
||||
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
||||
<g id="Artboard" sketch:type="MSArtboardGroup" fill="#FFFFFF">
|
||||
<path d="M22,20.08 C21.24,20.08 20.56,20.38 20.04,20.85 L12.91,16.7 C12.96,16.47 13,16.24 13,16 C13,15.76 12.96,15.53 12.91,15.3 L19.96,11.19 C20.5,11.69 21.21,12 22,12 C23.66,12 25,10.66 25,9 C25,7.34 23.66,6 22,6 C20.34,6 19,7.34 19,9 C19,9.24 19.04,9.47 19.09,9.7 L12.04,13.81 C11.5,13.31 10.79,13 10,13 C8.34,13 7,14.34 7,16 C7,17.66 8.34,19 10,19 C10.79,19 11.5,18.69 12.04,18.19 L19.16,22.35 C19.11,22.56 19.08,22.78 19.08,23 C19.08,24.61 20.39,25.92 22,25.92 C23.61,25.92 24.92,24.61 24.92,23 C24.92,21.39 23.61,20.08 22,20.08 L22,20.08 Z" id="Shape" sketch:type="MSShapeGroup"></path>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 1.2 KiB |