BEIJING - The earthquake and tsunami that devastated northern Japan may help temporarily ease Japan's strained relations with China, allowing the two Asian rivals for the moment to look past lingering territorial, economic, military and historical disputes.

When news of the disaster spread Friday, Chinese leaders were quick to offer condolences and support. China is also earthquake-prone - a deadly 5.8-magnitude tremor just hit southwestern Yunnan province Thursday - and officials here immediately put a trained rescue team in place to dispatch to Japan if needed.

The Chinese defense minister, Liang Guanglie, called his Japanese counterpart, Toshimi Kitazawa, to offer military assets. The Red Cross Society of China pledged 1 million yuan, or about $152,087, to help Japan. Chinese premier Wen Jiabao also had a telephone conversation Friday with Japanese Prime Minister Naoto Kan and offered China's condolences and help.

China's rapid show of sympathy and solidarity toward an Asian neighbor in distress stands in sharp contrast to the heated rhetoric of the past half-year, which saw noisy anti-Japanese demonstrations in some cities and the canceling of some ministry-level exchanges and tour groups.

After the earthquake, officially sanctioned editorials - which are regularly used to whip up anti-Japanese sentiment - were instead talking about shared pain and what China can learn from Japan's rapid and orderly response to the disaster.

An unsigned commentary Saturday from Xinhua, the official state-run news agency, recalled how Japan assisted China after a deadly earthquake in Sichuan province in 2008, with many ordinary Japanese lining up to make donations and a Japanese rescue team helping recover victims.

"The willingness and readiness to help each other is just a natural reflection of the time-honored friendly bond between the two neighboring Oriental civilizations," the commentary said. "The virtue of returning the favor after receiving one runs in the bloods of both nations."

Relations between the two Asian powers have long been strained but reached a new low in September, when a Chinese fishing trawler collided with two Japanese coast guard vessels around a small chain of disputed, Japanese-administered islands known as the Senkaku to the Japanese and the Diaoyu to the Chinese.

Japan briefly detained the Chinese trawler's captain and threatened to put him on trial, and China responded by blocking its exports to Japan of crucial rare earth metals used in the high-tech industry. The block on rare earth metals was widely interpreted as a de facto trade embargo imposed by Beijing, prompting Japan, the United States and other countries to scramble for alternatives to China's rare earth metals.

At the height of the fishing trawler incident last year, the Global Times newspaper - owned by the Communist Party's main mouthpiece, People's Daily, and typically giving voice to the party line - wrote a series of increasing vitriolic editorials calling for Japan to be punished.

"Now is the time to seriously examine Japan," one typical September editorial said. "It should be apparent by now that China will be forced to endure long-term conflicts with Japan, and emphasizing only friendly relations is not prudent. In addition, China needs to be certain of Japan's soft spots for clearly targeted reactions." It added, "The pain has to be piercing."

Japan has also been deeply concerned about China's growing military spending, with Beijing's Communist rulers this month announcing a 12.7 percent increase in the defense budget for 2011. And China's growing economic clout has led to fears that Beijing is becoming increasingly assertive in pressing its territorial claims in the region. China officially surpassed Japan last year as the world's second-largest economy, behind the United States.