Enable import all the nodes for android
Summary: Enables Import and Export for all the nodes for android. Also search and Accessibility feature works Reviewed By: danielbuechele Differential Revision: D14406016 fbshipit-source-id: 8976db66d1ca91e98c52983a31ea584764bde0f6
This commit is contained in:
committed by
Facebook Github Bot
parent
063d8aa416
commit
1c8fffa20b
@@ -49,7 +49,9 @@ export function searchNodes(
|
||||
AXMode: boolean,
|
||||
state: PersistedState,
|
||||
): ?SearchResultTree {
|
||||
const elements = state[propsForPersistedState(AXMode).ELEMENTS];
|
||||
// Even if the axMode is true, we will have to search the normal elements too.
|
||||
// The AXEelements will automatically populated in constructSearchResultTree
|
||||
const elements = state[propsForPersistedState(false).ELEMENTS];
|
||||
const children: Array<SearchResultTree> = [];
|
||||
const match = isMatch(node, query);
|
||||
|
||||
|
||||
@@ -83,10 +83,9 @@ function populateChildren(state: PersistedState, axMode: boolean) {
|
||||
'child1_child1 view',
|
||||
[],
|
||||
);
|
||||
state.elements = elements;
|
||||
if (axMode) {
|
||||
state.AXelements = elements;
|
||||
} else {
|
||||
state.elements = elements;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -67,11 +67,7 @@ export default class Layout extends FlipperPlugin<State, void, PersistedState> {
|
||||
if (!store) {
|
||||
return defaultPromise;
|
||||
}
|
||||
const selectedDevice = store.getState().connections.selectedDevice;
|
||||
if (selectedDevice && selectedDevice.os === 'iOS') {
|
||||
return callClient('getAllNodes').then(({allNodes}) => allNodes);
|
||||
}
|
||||
return defaultPromise;
|
||||
return callClient('getAllNodes').then(({allNodes}) => allNodes);
|
||||
};
|
||||
|
||||
static defaultPersistedState = {
|
||||
|
||||
Reference in New Issue
Block a user