Everything is determined by Allah’s will. Allah (swt) says:
{ وَلَا تَقُولَنَّ لِشَيْءٍ إِنِّي فَاعِلٌ ذَٰلِكَ غَدًا}
(And never say of anything, “Indeed, I will do that tomorrow,”.) (Al-Kahf: 23)
Allah (swt) knows what the creatures do openly and what they hide, whether it be statements or deeds. None of that is hidden from Him. Allah says:
{وَإِن تَجْهَرْ بِالْقَوْلِ فَإِنَّهُ يَعْلَمُ السِّرَّ وَأَخْفَى}
(And if you speak aloud – then indeed, He knows the secret and what is [even] more hidden.) (Ta-Ha: 7)
The secret is between two persons whereas the hidden is what is kept inside the heart of the person.