I grew up in Muscat (but an expat, not Omani) was there until I was 15. It's quite sad to read all the posters on here tarring an entire region with one broad ignorant brush as "unsafe" or bad for women without any knowledge.
The city is beautiful, chilled out, safe, friendly, and nothing like most other parts of the Middle East. There isn't the glitzy OTT glamour of Dubai, but it's got a lot of old world charm and natural beauty. It's quite progressive in that women are not expected to cover their heads or prevented from driving etc.
As with many other countries in the Middle East, you have to follow local laws. Getting drunk, attempting to bring in drugs etc are all strict no nos. Shoplifting or any attempt at theft are dealt with as per Islamic law. Public displays of affection are disallowed. But none of these rules are particularly hard to follow unless you're being deliberately obtuse.
As a kid I loved the corniche, the various parks, esp nizam gardens, and the weather is brilliant in the winter.
As for your ex and the dynamic - that's something for you to figure out, but as a non-Omani he won't have any rights to keep your daughter with him at the end of the stay. But you will need separate accommodation since it won't be a good idea to stay with him.