Chinese people often do not think about the people around them. This is not really a racial stereotype as much as it is a cultural difference when compared with societies that focus on the individual rather than the group.
Generally speaking, they're not doing it on purpose in order to spite you because you're a foreigner - they are simply not accustomed to being considerate beyond the basics. For example, it's very common for Chinese people to stop moving as soon as they exit a subway train or get off an escalator: it simply doesn't occur to them that they will be inconveniencing others by not deciding where they're going without stopping.
Chinese people will often have loud conversations or talk on their mobile phones in places that are inconsiderate to those around them, such as at the cinema. Generally speaking (though not always), their behaviour is not malicious and if you point out that they're being inconsiderate to others, they will generally be apologetic.
Chinese people do not value politeness in general as much as western society, so do not expect to be thanked for holding the door open for someone, or for allowing somebody to board a bus or subway car before you.
QueueingGiven the fact that it is the most populated country in the world and there are over 23 million people living in Shanghai alone, you might imagine that Chinese culture would have developed an intricate system of crowd etiquette by now, in order to better accommodate the demands of its constantly burgeoning population.
When it comes to queueing, China really has little to no etiquette regarding the matter. Although the westernisation of Shanghai means that more places are more likely to enforce queuing, many places are a little more of a free-for-all. Expect 'creative' queuing, plenty of jostling, and frequent attempts to cut in line. Unfortunately, the only way to get what you want is to engage in 'Chinese queueing' yourself.
Chinese people are queue opportunists: if they see a gap, they'll try to move into it. Even if they see an obvious queue, it's quite common for them to attempt to skip to the front, just in case it's a possibility. However, if somebody makes a fuss and calls them out on it, they will more often than not sheepishly return to the line. In cases like these, you can make liberal use of the phrase 排队！ - páiduì - "line up!".
On a related note, Chinese people generally do not follow the common sense notion of letting people get off the bus/subway car before getting on themselves. Be prepared to have to throw a few elbows when getting off public transport, as you will usually have somebody trying just as hard to get on. A useful phrase here is 先下，后上！ - xiān xià, hòu shàng - "first (let others) get off, then (you can) get on!".
When doors open at a crowded stop and there are only a few seats available, you will generally witness a free-for-all as the Chinese people rush and compete for the empty seats. Unless it's a priority seat (and sometimes not even then), elderly or infirm people be damned!
A great many Chinese people also haven't yet worked out - even though it is usually clearly signposted - the intricacies of standing on the right side of an escalator while allowing people to walk up the left side. Unless they're in a rush, the vast majority of Chinese people will simply load themselves onto the middle of the escalator and then stand stock still until they reach the top. You can try a simple 不好意思 (bù hǎoyìsi - "excuse me") or even the super polite 劳驾 (láojià - "excuse me") to show that you want to get through, but if you want to help explain your frustration, you can try 左走，右立！ - zuǒ zǒu, yòu lì - "walk on the left, stand on the right!".
Although Chinese people living in Shanghai have seen their fair share of lǎowài and are no longer particularly surprised or curious to see them around the city, you should still expect to be stared at occasionally on public transport, or when walking on the street. This is especially true if you have any particularly non-Chinese features (e.g. blonde hair, being very tall or fat, lots of facial hair, etc.). If you travel to smaller cities or rural areas where foreign visitors are uncommon, you should prepare to be gawked at pretty much non-stop.
Chinese people generally stare out of curiosity, not out of disapproval - there is no social stigma in China attached to staring at people. Try not to get aggressive or defensive about it: in fact, the best way to react when somebody is staring intently at you is simply to smile and throw them a 你好 - nǐ hǎo - "hello". Some will smile back and return the greeting, some will immediately avert their gaze.
Young children and babies will very often stare at westerners, because to them it's especially unusual to see a non-Chinese face. Chinese people love it when you smile, wave and say hello (especially in English!) to their children. Most children will be shy and act bashful or try to hide behind their parent's legs.
Chinese people traditionally see punctuality as a virtue, and will try to be on time - or preferably early - for everything. If arranging to meet friends or clients somewhere, try your best to be slightly early, as tardiness without a valid excuse may be seen as disrespectful.
Many other cultures (e.g. Germany or Japan) place a similar level of importance on punctuality, and trying to arrive to appointments 5 to 10 minutes early as a general rule of thumb in China is not a bad idea.