In all fairness, China is the future. Its economy will soon be the largest in the world and no major Western company wants to miss out on that. In the 20th century, foreign companies kissed up to the US government in exchange for economic access, in the 21 century, American and Western companies will kiss up to China for access to their economy. It's just how the world works.
Want to make yourself invaluable to most western companies for the next 40 years? Learn mandarin.
Except China is either cutting off access or doing things that making investment there
very risky. India is now looking like the new place to have cheap goods made.
Also China has the problem many Western countries have - an aging population. As outlined in Time magazine's
China’s Aging Population Is a Major Threat to Its Future:
"If current trends continue, China’s population will peak at 1.44 billion in 2029 before entering “unstoppable” decline, according to a Chinese Academy of Social Sciences study released in January."
"All signs suggest the country will get old before it gets rich–and the impact is already making itself felt."
Then there is China's 'it can't go on forever' housing bubble -
China’s Real Estate Bubble Started With ‘State Capitalism’ That market has already seen a mammoth slowdown (new home sales dropped by a third)
China's command economy can only stave off the 'here is what happened to the US in 2008' moment for so long and barring some major restructuring (which would require loosing face as they would be admitting to the world they messed up) a major contraction of China's economy in the next 20 years is very possible.