Heat 2 tablespoons olive oil in frying pan over medium heat. Add diced onion and cook for 5 minutes or so, stirring often, until softened. Transfer to a casserole pot.
Combine the flour, salt and pepper in a bowl. Add chicken thighs and toss to coat in the seasoned flour.
Heat 2 more tablespoons oil in frying pan over medium heat. Fry floured chicken thighs for 5 minutes on one side without turning - this will allow them to develop a golden colour. Turn and cook on the other side for another few minutes. Transfer to the casserole pot. Pour white wine into the frying pan and bring to the boil. Stir to catch all the bits of chicken and flavours in the pan; add to casserole.
Add tinned tomatoes, tomato paste, salt, pepper and sugar. Pour over as much chicken stock as needed to cover the chicken. Cover casserole pot and simmer over medium low heat for 45 minutes, or until chicken is cooked through, stirring every so often.
Just before serving, add fresh parsley, basil and olives. Stir to heat through. Check seasoning, adding more salt, pepper or sugar, as needed.