What if you go to the gym consistently 3 times a week and have been for the last year or two yet predominantly sit for hours throughout the week in your day job due to the environment you are in. If you have a desk job and find yourself sitting for at least 15-20 hours a week, just in work, then the 3 hours of gym time must be used productively.
Don't sit on Machines in the gym, they all have a seat and isolating one muscle group isn't going to shift any excess fat, or improve your health.
Move the body in the gym and work on compound moves that target more than one muscle group at any one time.
If you have no choice to sit at work, try standing as often as possible and limit high GI fruits that need to be used as energy straight away, such as grapes.
Always get a balance of fats, carbs, and protein when snacking.
Make stretching a daily occurrence. When sat for long periods it doesn't take long before the hamstrings, hipflexors start feeling tight, and over time will become about as flexible as bark from a tree. Stretch each night before bed.
Speak to your HR department about getting a retractable desk.