Mix flour, salt, pepper and thyme in a plastic bag. Shake chicken to coat well.
In a frying pan, brown chicken in butter. Remove chicken and place in a casserole dish. Add onions and mushrooms to the frying pan; cover and simmer for 3 minutes. Pour the onions, mushrooms and butter over the chicken.
Mix together the lemon juice, sugar, salt and apple juice. Pour over the chicken.