Get focus position after auto focus using v4l2 - camera

Its possible to get the focus position after a auto focus call with v4l2 (V4L2_CID_FOCUS_AUTO).
I know its possible to get the status (focused or not) using V4L2_CID_AUTO_FOCUS_STATUS, but I need the exact position after the auto focus.

Related

i want to scroll a voew to right and click on 3 dots, sometimes automatically it detects the button, sometimes not

I have to scroll right in cypress for a specific view part. Sometimes it automatically detect, but sometimes after scroll only it detect the button. Scrollbar has no unique ID. What is the solution for this scenario?
I tried cy.scroll(500,0) but this dont work
You can get the element then use .scrollIntoView() chained to the returned element.
cy.get('#uniqueId')
.scrollIntoView()
// now it will be in current viewport

When keyboard is already open and render() updates to show a KeyboardAvoidingView (that it wasn't showing before) it does not avoid the keyboard

So I have a restaurant listing with a filter at the top and below that the restaurants are updated as you type to match your filter. When your filter does not return anything the view is then changed to show a "No restaurants found, change your filter" type message. I have this set up as a KeyboardAvoidingView because I wanted it centered vertically, and when you have the keyboard open it's sitting just barely above it, and doesn't look great. With the view active however it's pushed up a bit and becomes centered with what is visible.
My problem is that once the filter is used enough to hide all restaurants, the KAV is then shown in the render function but doesn't recognize that the keyboard is open and it needs to move. If I get to that stage and then close/re-open the keyboard it works, but that is far from ideal.
I've already checked out this thread and tried the solution found there: KeyboardAvoidingView - Reset height when Keyboard is hidden but that did not work for me unfortunately.
And this thread seems to have the same problem as I do: react native KeyboardAvoidingView with already opened keyboard dont work properly but the solution was to hide the keyboard, which I do not want. I want them to correct their input and reduce the filter immediately using the already-open keyboard.
Is there a way I can introduce the KAV after the keyboard is already open and have it react to the already-opened keyboard?

disabling Windows phone map control

My quesiton is: i have a windows phone 8 app - it has a Map Control on a page that shows the user's position.
We want to allow the user to disable the map control so it looks greyed out and disbaled and doesnt update (to save bandwith etc)
What would be the best way of doing this?
I would simply draw a control with semitransparent background on top of the map. thus all touch events would be stuck in the control, but the map would be visible under it still.

Elastic property with windows phone slider

I have a slider in windows phone as shown in figure. When I swipe the slider it's working. But what I want is, if I swipe the slider and leave it in the middle without reaching the end of the slider - it should return back to the beginning like elastic. If it was swiped to the end then it should navigate to the next page. Why I am using slider is, I need to control a text's opacity with animation. How to do this task?
I would use VisualStates to provide the animation, then you don't have to worry about the physics of it. I have created a similar scenario for a notification style Windows Phone effect, you know how you can swipe a notification off to the right. Basically it would be something like this:
OnManipulationStarted VisualStateManager.GoToState for OpenBegin or ClosedBegin depending on the state
OnManipulationDelta you can check e.Delta.X and if < 0 its moving left otherwise it's moving right or just check the position OnManipulationCompleted
After you know what the state call VisualStateManager.GoToState for OpenEnd or ClosedEnd and it will animate back to the specified location.
Add a comment if you need more help/code

Events generated when grabbing and moving the WinRT app window from the top edge with the mouse?

On Windows 8, what kind of events are generated when moving the mouse cursor to the top edge and then click-dragging downwards with the left mouse button? It brings the window to a state where it can be docked to either side of the screen or exited by dragging it to the bottom of the screen.
You do get the mouse move events, but there are no events fired to tell you that your app COULD change it's layout. You will be told when the app is snapped, filled, or landscape/portrait. If you are using the LayoutAwarePage, you will be told within the DetermineVisualState method.
protected override string DetermineVisualState(ApplicationViewState viewState)
{
// Use the viewState property to determine layout
return base.DetermineVisualState(viewState);
}
It's the Activated event in Windows::UI::Core::CoreWindow. The callback function's args variable gives a WindowActivationState (Deactivated, CodeActivated or PointerActivated). An example of how to implement it can be found in the Microsoft XAML DirectX 3d shooting game sample.